CC-1927 Remove PEAR DB
Removed remaining references to $CC_DBC
This commit is contained in:
parent
96b010e7f0
commit
9ec584e90c
4 changed files with 11 additions and 13 deletions
|
@ -102,8 +102,6 @@ class Bootstrap extends Zend_Application_Bootstrap_Bootstrap
|
||||||
protected function _initZFDebug()
|
protected function _initZFDebug()
|
||||||
{
|
{
|
||||||
if (APPLICATION_ENV == "development"){
|
if (APPLICATION_ENV == "development"){
|
||||||
global $CC_DBC;
|
|
||||||
|
|
||||||
$autoloader = Zend_Loader_Autoloader::getInstance();
|
$autoloader = Zend_Loader_Autoloader::getInstance();
|
||||||
$autoloader->registerNamespace('ZFDebug');
|
$autoloader->registerNamespace('ZFDebug');
|
||||||
|
|
||||||
|
|
|
@ -4,11 +4,12 @@ require_once(dirname(__FILE__)."/../Schedule.php");
|
||||||
|
|
||||||
class SchedulerExportTests extends PHPUnit_TestCase {
|
class SchedulerExportTests extends PHPUnit_TestCase {
|
||||||
function setup() {
|
function setup() {
|
||||||
global $CC_CONFIG, $CC_DBC;
|
global $CC_CONFIG;
|
||||||
|
$con = Propel::getConnection();
|
||||||
|
|
||||||
// Clear the files table
|
// Clear the files table
|
||||||
$sql = "DELETE FROM ".$CC_CONFIG["filesTable"];
|
$sql = "DELETE FROM ".$CC_CONFIG["filesTable"];
|
||||||
$CC_DBC->query($sql);
|
$con->exec($sql);
|
||||||
|
|
||||||
// Add a file
|
// Add a file
|
||||||
$values = array("filepath" => dirname(__FILE__)."/test10001.mp3");
|
$values = array("filepath" => dirname(__FILE__)."/test10001.mp3");
|
||||||
|
@ -20,7 +21,7 @@ class SchedulerExportTests extends PHPUnit_TestCase {
|
||||||
|
|
||||||
// Clear the schedule table
|
// Clear the schedule table
|
||||||
$sql = "DELETE FROM ".$CC_CONFIG["scheduleTable"];
|
$sql = "DELETE FROM ".$CC_CONFIG["scheduleTable"];
|
||||||
$CC_DBC->query($sql);
|
$con->exec($sql);
|
||||||
|
|
||||||
// Create a playlist
|
// Create a playlist
|
||||||
$playlist = new Application_Model_Playlist();
|
$playlist = new Application_Model_Playlist();
|
||||||
|
|
|
@ -8,11 +8,10 @@ class SchedulerTests extends PHPUnit_TestCase {
|
||||||
private $storedFile2;
|
private $storedFile2;
|
||||||
|
|
||||||
function setup() {
|
function setup() {
|
||||||
global $CC_CONFIG, $CC_DBC;
|
global $CC_CONFIG;
|
||||||
|
|
||||||
// Clear the files table
|
// Clear the files table
|
||||||
//$sql = "DELETE FROM ".$CC_CONFIG["filesTable"];
|
//$sql = "DELETE FROM ".$CC_CONFIG["filesTable"];
|
||||||
//$CC_DBC->query($sql);
|
|
||||||
|
|
||||||
// Add a file
|
// Add a file
|
||||||
$values = array("filepath" => dirname(__FILE__)."/test10001.mp3");
|
$values = array("filepath" => dirname(__FILE__)."/test10001.mp3");
|
||||||
|
@ -24,7 +23,6 @@ class SchedulerTests extends PHPUnit_TestCase {
|
||||||
|
|
||||||
// Clear the schedule table
|
// Clear the schedule table
|
||||||
//$sql = "DELETE FROM ".$CC_CONFIG["scheduleTable"];
|
//$sql = "DELETE FROM ".$CC_CONFIG["scheduleTable"];
|
||||||
//$CC_DBC->query($sql);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function testDateToId() {
|
function testDateToId() {
|
||||||
|
|
|
@ -15,12 +15,13 @@ require_once __DIR__.'/../../../library/propel/runtime/lib/Propel.php';
|
||||||
Propel::init(__DIR__.'/../../configs/airtime-conf.php');
|
Propel::init(__DIR__.'/../../configs/airtime-conf.php');
|
||||||
|
|
||||||
AirtimeInstall::DbConnect(true);
|
AirtimeInstall::DbConnect(true);
|
||||||
|
$con = Propel::getConnection();
|
||||||
$sql = "DELETE FROM cc_show";
|
$sql = "DELETE FROM cc_show";
|
||||||
$CC_DBC->query($sql);
|
$con->exec($sql);
|
||||||
$sql = "DELETE FROM cc_show_days";
|
$sql = "DELETE FROM cc_show_days";
|
||||||
$CC_DBC->query($sql);
|
$con->exec($sql);
|
||||||
$sql = "DELETE FROM cc_show_instances";
|
$sql = "DELETE FROM cc_show_instances";
|
||||||
$CC_DBC->query($sql);
|
$con->exec($sql);
|
||||||
|
|
||||||
/*
|
/*
|
||||||
// Create a playlist
|
// Create a playlist
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue