CC-1927 Remove PEAR DB
Removed remaining references to $CC_DBC
This commit is contained in:
parent
96b010e7f0
commit
9ec584e90c
|
@ -102,8 +102,6 @@ class Bootstrap extends Zend_Application_Bootstrap_Bootstrap
|
|||
protected function _initZFDebug()
|
||||
{
|
||||
if (APPLICATION_ENV == "development"){
|
||||
global $CC_DBC;
|
||||
|
||||
$autoloader = Zend_Loader_Autoloader::getInstance();
|
||||
$autoloader->registerNamespace('ZFDebug');
|
||||
|
||||
|
|
|
@ -4,11 +4,12 @@ require_once(dirname(__FILE__)."/../Schedule.php");
|
|||
|
||||
class SchedulerExportTests extends PHPUnit_TestCase {
|
||||
function setup() {
|
||||
global $CC_CONFIG, $CC_DBC;
|
||||
global $CC_CONFIG;
|
||||
$con = Propel::getConnection();
|
||||
|
||||
// Clear the files table
|
||||
$sql = "DELETE FROM ".$CC_CONFIG["filesTable"];
|
||||
$CC_DBC->query($sql);
|
||||
$con->exec($sql);
|
||||
|
||||
// Add a file
|
||||
$values = array("filepath" => dirname(__FILE__)."/test10001.mp3");
|
||||
|
@ -20,7 +21,7 @@ class SchedulerExportTests extends PHPUnit_TestCase {
|
|||
|
||||
// Clear the schedule table
|
||||
$sql = "DELETE FROM ".$CC_CONFIG["scheduleTable"];
|
||||
$CC_DBC->query($sql);
|
||||
$con->exec($sql);
|
||||
|
||||
// Create a playlist
|
||||
$playlist = new Application_Model_Playlist();
|
||||
|
|
|
@ -8,11 +8,10 @@ class SchedulerTests extends PHPUnit_TestCase {
|
|||
private $storedFile2;
|
||||
|
||||
function setup() {
|
||||
global $CC_CONFIG, $CC_DBC;
|
||||
global $CC_CONFIG;
|
||||
|
||||
// Clear the files table
|
||||
//$sql = "DELETE FROM ".$CC_CONFIG["filesTable"];
|
||||
//$CC_DBC->query($sql);
|
||||
|
||||
// Add a file
|
||||
$values = array("filepath" => dirname(__FILE__)."/test10001.mp3");
|
||||
|
@ -24,7 +23,6 @@ class SchedulerTests extends PHPUnit_TestCase {
|
|||
|
||||
// Clear the schedule table
|
||||
//$sql = "DELETE FROM ".$CC_CONFIG["scheduleTable"];
|
||||
//$CC_DBC->query($sql);
|
||||
}
|
||||
|
||||
function testDateToId() {
|
||||
|
|
|
@ -15,12 +15,13 @@ require_once __DIR__.'/../../../library/propel/runtime/lib/Propel.php';
|
|||
Propel::init(__DIR__.'/../../configs/airtime-conf.php');
|
||||
|
||||
AirtimeInstall::DbConnect(true);
|
||||
$con = Propel::getConnection();
|
||||
$sql = "DELETE FROM cc_show";
|
||||
$CC_DBC->query($sql);
|
||||
$con->exec($sql);
|
||||
$sql = "DELETE FROM cc_show_days";
|
||||
$CC_DBC->query($sql);
|
||||
$con->exec($sql);
|
||||
$sql = "DELETE FROM cc_show_instances";
|
||||
$CC_DBC->query($sql);
|
||||
$con->exec($sql);
|
||||
|
||||
/*
|
||||
// Create a playlist
|
||||
|
@ -88,10 +89,10 @@ echo "End date: ".$endDate->format("Y-m-d H:i")."\n";
|
|||
while ($showTime < $endDate) {
|
||||
echo $showTime->format("Y-m-d H:i")." < " .$endDate->format("Y-m-d H:i")."\n";
|
||||
if ($resolution == "minute") {
|
||||
createTestShow($showNumber, $showTime, "0:01");
|
||||
createTestShow($showNumber, $showTime, "0:01");
|
||||
$showTime->add(new DateInterval("PT1M"));
|
||||
} elseif ($resolution == "hour") {
|
||||
createTestShow($showNumber, $showTime);
|
||||
createTestShow($showNumber, $showTime);
|
||||
$showTime->add(new DateInterval("PT1H"));
|
||||
}
|
||||
$showNumber = $showNumber + 1;
|
||||
|
|
Loading…
Reference in New Issue