Initial ugly re-factor of where fixtures are done.

This commit is contained in:
mark_story 2011-02-12 16:45:26 -05:00
parent 5a631a6c74
commit f586ed0394

View file

@ -27,14 +27,16 @@ PHP_CodeCoverage_Filter::getInstance()->addFileToBlacklist(__FILE__, 'DEFAULT');
*/ */
class CakeTestRunner extends PHPUnit_TextUI_TestRunner { class CakeTestRunner extends PHPUnit_TextUI_TestRunner {
public function doRun(PHPUnit_Framework_Test $suite, array $arguments = array()) {
/** $fixture = new CakeFixtureManager;
* Sets the proper test suite to use and loads the test file in it. foreach ($suite->getIterator() as $test) {
* this method gets called as a callback from the parent class if ($test instanceof CakeTestCase) {
* $fixture->fixturize($test);
* @return void $test->fixtureManager = $fixture;
*/ }
protected function handleCustomTestSuite() { }
$r = parent::doRun($suite, $arguments);
$fixture->shutdown();
return $r;
} }
} }