]> src.bluestatic.org Git - isso.git/blob - UnitTest/DatabaseTests.php
Cleaing up error reporting and error triggering in Api.php
[isso.git] / UnitTest / DatabaseTests.php
1 <?php
2
3 require_once 'tests.config.php';
4 ini_set('include_path', ini_get('include_path') . ':' . TEST_PATH_TO_ISSO);
5
6 if (!defined('PHPUnit_MAIN_METHOD'))
7 {
8 define('PHPUnit_MAIN_METHOD', 'DatabaseTests');
9 }
10
11 require_once 'PHPUnit/Framework.php';
12 require_once 'PHPUnit/TextUI/TestRunner.php';
13
14 class DatabaseTests
15 {
16 public static function main()
17 {
18 PHPUnit_TextUI_TestRunner::run(self::suite());
19 }
20
21 public static function suite()
22 {
23 $suite = new PHPUnit_Framework_TestSuite('ISSO Database');
24
25 require_once 'DatabaseMySQLTest.php';
26 $suite->addTestSuite('DatabaseMySQLTest');
27
28 require_once 'DatabaseMySQLiTest.php';
29 $suite->addTestSuite('DatabaseMySQLiTest');
30
31 return $suite;
32 }
33 }
34
35 if (PHPUnit_MAIN_METHOD == 'DatabaseTests')
36 {
37 DatabaseTests::main();
38 }
39
40 ?>