Connect to db only after creating tables
This commit is contained in:
@@ -3,8 +3,6 @@ if(file_exists('/usr/lib/php5/mysql.auth.php')){
|
||||
include '/usr/lib/php5/mysql.auth.php';
|
||||
}
|
||||
include(dirname(__FILE__).'/test.config.php');
|
||||
include(dirname(__FILE__).'/test.includes.php');
|
||||
|
||||
|
||||
$dropDBCommand = 'echo "DROP DATABASE IF EXISTS ' . APP_DB . '"| mysql -u' . MYSQL_ROOT_USER . ' -p' . MYSQL_ROOT_PASS;
|
||||
$createDBCommand = 'echo "CREATE DATABASE '.APP_DB.'"| mysql -u'.MYSQL_ROOT_USER.' -p'.MYSQL_ROOT_PASS;
|
||||
@@ -30,5 +28,5 @@ foreach ($scripts as $insql){
|
||||
$command = "cat ".$insql."| mysql -u".MYSQL_ROOT_USER." -p".MYSQL_ROOT_PASS." '".APP_DB."'";
|
||||
exec($command);
|
||||
}
|
||||
|
||||
include(dirname(__FILE__).'/test.includes.php');
|
||||
echo "Bootstrapping done!!"."\r\n";
|
||||
|
||||
@@ -1,9 +1,4 @@
|
||||
<?php
|
||||
if(!defined('TEST_BASE_PATH')){
|
||||
include(dirname(__FILE__).'/test.config.php');
|
||||
}
|
||||
|
||||
|
||||
//Mock Session class
|
||||
if (!class_exists('SessionUtils')) {
|
||||
class SessionUtils{
|
||||
|
||||
Reference in New Issue
Block a user