Replace constant DEBUG to use in Config. Remove start profiler from FrontController (moved to bootstrap).
This commit is contained in:
@ -57,9 +57,7 @@ class MySQLiDriverTest extends PHPUnit_Extensions_Database_TestCase
|
||||
*/
|
||||
public function testDriver()
|
||||
{
|
||||
if (!defined('DEBUG')) {
|
||||
define('DEBUG', false);
|
||||
}
|
||||
Config::set('DEBUG', 0);
|
||||
|
||||
$driver = new MySQLiDriver($this->conf);
|
||||
|
||||
@ -78,9 +76,7 @@ class MySQLiDriverTest extends PHPUnit_Extensions_Database_TestCase
|
||||
*/
|
||||
public function testGetConnection()
|
||||
{
|
||||
if (!defined('DEBUG')) {
|
||||
define('DEBUG', false);
|
||||
}
|
||||
Config::set('DEBUG', 0);
|
||||
|
||||
$driver = new MySQLiDriver($this->conf);
|
||||
$this->assertInstanceOf('mysqli', $driver->getConnection());
|
||||
@ -91,9 +87,7 @@ class MySQLiDriverTest extends PHPUnit_Extensions_Database_TestCase
|
||||
*/
|
||||
public function testGetConnectionWrongConfig()
|
||||
{
|
||||
if (!defined('DEBUG')) {
|
||||
define('DEBUG', false);
|
||||
}
|
||||
Config::set('DEBUG', 0);
|
||||
$this->conf['database'] = 'nodb';
|
||||
$driver = new MySQLiDriver($this->conf);
|
||||
|
||||
@ -106,9 +100,7 @@ class MySQLiDriverTest extends PHPUnit_Extensions_Database_TestCase
|
||||
*/
|
||||
public function testDisconnect()
|
||||
{
|
||||
if (!defined('DEBUG')) {
|
||||
define('DEBUG', false);
|
||||
}
|
||||
Config::set('DEBUG', 0);
|
||||
|
||||
$driver = new MySQLiDriver($this->conf);
|
||||
|
||||
@ -125,9 +117,7 @@ class MySQLiDriverTest extends PHPUnit_Extensions_Database_TestCase
|
||||
*/
|
||||
public function testInsert()
|
||||
{
|
||||
if (!defined('DEBUG')) {
|
||||
define('DEBUG', false);
|
||||
}
|
||||
Config::set('DEBUG', 0);
|
||||
|
||||
$driver = new MySQLiDriver($this->conf);
|
||||
|
||||
@ -147,9 +137,7 @@ class MySQLiDriverTest extends PHPUnit_Extensions_Database_TestCase
|
||||
*/
|
||||
public function testGetInsertId()
|
||||
{
|
||||
if (!defined('DEBUG')) {
|
||||
define('DEBUG', false);
|
||||
}
|
||||
Config::set('DEBUG', 0);
|
||||
|
||||
$driver = new MySQLiDriver($this->conf);
|
||||
|
||||
@ -161,9 +149,7 @@ class MySQLiDriverTest extends PHPUnit_Extensions_Database_TestCase
|
||||
*/
|
||||
public function testTransaction()
|
||||
{
|
||||
if (!defined('DEBUG')) {
|
||||
define('DEBUG', false);
|
||||
}
|
||||
Config::set('DEBUG', 0);
|
||||
|
||||
$driver = new MySQLiDriver($this->conf);
|
||||
|
||||
@ -194,9 +180,7 @@ class MySQLiDriverTest extends PHPUnit_Extensions_Database_TestCase
|
||||
*/
|
||||
public function testRollback()
|
||||
{
|
||||
if (!defined('DEBUG')) {
|
||||
define('DEBUG', false);
|
||||
}
|
||||
Config::set('DEBUG', 0);
|
||||
|
||||
$driver = new MySQLiDriver($this->conf);
|
||||
|
||||
|
Reference in New Issue
Block a user