diff --git a/lib/Cake/TestSuite/CakeTestRunner.php b/lib/Cake/TestSuite/CakeTestRunner.php index f6a7b976d..29c451b8e 100644 --- a/lib/Cake/TestSuite/CakeTestRunner.php +++ b/lib/Cake/TestSuite/CakeTestRunner.php @@ -53,6 +53,7 @@ class CakeTestRunner extends PHPUnit_TextUI_TestRunner { * @param PHPUnit_Framework_Test $suite The test suite to run * @param array $arguments The CLI arguments * @param bool $exit Exits by default or returns the results + * This argument is ignored if >PHPUnit5.2.0 * @return void */ public function doRun(PHPUnit_Framework_Test $suite, array $arguments = array(), $exit = true) { @@ -72,7 +73,7 @@ class CakeTestRunner extends PHPUnit_TextUI_TestRunner { } } - $return = parent::doRun($suite, $arguments); + $return = parent::doRun($suite, $arguments, $exit); $fixture->shutdown(); return $return; } diff --git a/lib/Cake/TestSuite/CakeTestSuiteCommand.php b/lib/Cake/TestSuite/CakeTestSuiteCommand.php index c760d5d59..9e1cda5fc 100644 --- a/lib/Cake/TestSuite/CakeTestSuiteCommand.php +++ b/lib/Cake/TestSuite/CakeTestSuiteCommand.php @@ -95,7 +95,7 @@ class CakeTestSuiteCommand extends PHPUnit_TextUI_Command { unset($this->arguments['testFile']); try { - $result = $runner->doRun($suite, $this->arguments); + $result = $runner->doRun($suite, $this->arguments, false); } catch (PHPUnit_Framework_Exception $e) { print $e->getMessage() . "\n"; }