Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
edorian committed Nov 24, 2012
1 parent 0809359 commit 302b465
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 5 deletions.
1 change: 1 addition & 0 deletions ChangeLog.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,4 +9,5 @@ PHPUnit 3.8.0
* A test will now fail in strict mode when it uses the `@covers` annotation and code that is not expected to be covered is executed.
* Implemented #711: `coverage-text` now has an XML `showOnlySummary` option.
* Fixed: `phpt` test cases now use the correct php binary when executed through wrapper scripts.
* Implemented #719: The `--stderr` flag now respects `--colors` and `--debug`.
* PHPUnit 3.8 is only supported on PHP 5.4.7 (or later).
15 changes: 10 additions & 5 deletions PHPUnit/TextUI/Command.php
Original file line number Diff line number Diff line change
Expand Up @@ -415,11 +415,7 @@ protected function handleArguments(array $argv)
break;

case '--stderr': {
$this->arguments['printer'] = new PHPUnit_TextUI_ResultPrinter(
'php://stderr',
isset($this->arguments['verbose']) ? $this->arguments['verbose'] : FALSE
);
}
$this->arguments['stderr'] = true; }
break;

case '--stop-on-error': {
Expand Down Expand Up @@ -512,6 +508,15 @@ protected function handleArguments(array $argv)
}
}

if (isset($this->arguments['stderr'])) {
$this->arguments['printer'] = new PHPUnit_TextUI_ResultPrinter(
'php://stderr',
isset($this->arguments['verbose']) ?: FALSE,
isset($this->arguments['colors']) ?: FALSE,
isset($this->arguments['debug']) ?: FALSE
);
}

$this->handleCustomTestSuite();

if (!isset($this->arguments['test'])) {
Expand Down

0 comments on commit 302b465

Please sign in to comment.