Skip to content

Commit

Permalink
Merge pull request #182 from wolak/master
Browse files Browse the repository at this point in the history
Adds more detailed message when printing feedback
  • Loading branch information
julianseeger committed Nov 2, 2015
2 parents 8122714 + 8f44372 commit 904a8c1
Showing 1 changed file with 12 additions and 1 deletion.
13 changes: 12 additions & 1 deletion src/ParaTest/Runners/PHPUnit/ResultPrinter.php
Original file line number Diff line number Diff line change
Expand Up @@ -189,7 +189,18 @@ public function printResults()
*/
public function printFeedback(ExecutableTest $test)
{
$reader = new Reader($test->getTempFile());
try {
$reader = new Reader($test->getTempFile());
} catch (\InvalidArgumentException $e) {
throw new \RuntimeException(sprintf(
"%s\n" .
"The process: %s\n" .
"This means a PHPUnit process was unable to run \"%s\"\n" ,
$e->getmessage(),
$test->getLastCommand(),
$test->getPath()
));
}
if (!$reader->hasResults()) {
throw new \RuntimeException(sprintf(
"The process: %s\nLog file \"%s\" is empty.\n" .
Expand Down

0 comments on commit 904a8c1

Please sign in to comment.