cvs: pear /MDB/tests test.php
| From: | Lukas Smith | Date: | Sat, 18 Jan 2003 21:34:26 +0000 |
| Subject: | cvs: pear /MDB/tests test.php | ||
| Groups: | php.pear.cvs | ||
| Request: | Send a blank email to pear-cvs+get-8389@lists.php.net to get a copy of this message | ||
lsmith Sat Jan 18 16:34:26 2003 EDT
Modified files:
/pear/MDB/tests test.php
Log:
fixed a warning
added code to extend max execution time if needed
cs improvements
Index: pear/MDB/tests/test.php
diff -u pear/MDB/tests/test.php:1.15 pear/MDB/tests/test.php:1.16
--- pear/MDB/tests/test.php:1.15 Fri Dec 20 12:53:11 2002
+++ pear/MDB/tests/test.php Sat Jan 18 16:34:26 2003
@@ -41,7 +41,7 @@
// | Author: Paul Cooper <pgc@ucecom.com> |
// +----------------------------------------------------------------------+
//
-// $Id: test.php,v 1.15 2002/12/20 17:53:11 lsmith Exp $
+// $Id: test.php,v 1.16 2003/01/18 21:34:26 lsmith Exp $
/*
This is a small test suite for MDB using PHPUnit
@@ -57,21 +57,24 @@
}
ini_set('include_path', '..'.PATH_SEPARATOR.ini_get('include_path'));
-require_once 'PHPUnit.php';
-require_once 'test_setup.php';
-require_once 'testUtils.php';
-require_once 'MDB.php';
+require_once('PHPUnit.php');
+require_once('test_setup.php');
+require_once('testUtils.php');
+require_once('MDB.php');
+
+// you may need to uncomment the line and modify the multiplier as you see fit
+// set_time_limit(120*count($dbarray));
MDB::loadFile('Manager');
MDB::loadFile('Date');
foreach ($testcases as $testcase) {
- include_once $testcase . '.php';
+ include_once($testcase.'.php');
}
$database = 'driver_test';
-$testmethods = $_POST['testmethods'];
+$testmethods = isset($_POST['testmethods']) ? $_POST['testmethods'] : NULL;
if (!is_array($testmethods)) {
foreach ($testcases as $testcase) {
@@ -99,7 +102,7 @@
}
}
-require_once 'HTML_TestListener.php';
+require_once('HTML_TestListener.php');
$result = new PHPUnit_TestResult;
$result->addListener(new HTML_TestListener);