2 set_include_path('{include_path}');
3 require_once 'PHPUnit/Autoload.php';
6 function __phpunit_run_isolated_test()
8 if (!class_exists('{className}')) {
9 require_once '{filename}';
12 $result = new PHPUnit_Framework_TestResult;
13 $result->collectRawCodeCoverageInformation({collectCodeCoverageInformation});
14 $result->strictMode({strict});
16 $test = new {className}('{methodName}', unserialize('{data}'), '{dataName}');
17 $test->setDependencyInput(unserialize('{dependencyInput}'));
18 $test->setInIsolation(TRUE);
23 $output = ob_get_clean();
27 'testResult' => $test->getResult(),
28 'numAssertions' => $test->getNumAssertions(),
41 if (isset($GLOBALS['__PHPUNIT_BOOTSTRAP'])) {
42 require_once $GLOBALS['__PHPUNIT_BOOTSTRAP'];
43 unset($GLOBALS['__PHPUNIT_BOOTSTRAP']);
46 __phpunit_run_isolated_test();