Permalink
Browse files

JUnitPrinter: fixed skip and failed count printing

Introduced in 11f4763
Disclosed by 50da9fb
  • Loading branch information...
milo committed Jul 31, 2017
1 parent 4f4eae6 commit 900febd77046ba9018720dbae0946db9ec37b50f
Showing with 2 additions and 2 deletions.
  1. +1 βˆ’1 src/Runner/Output/JUnitPrinter.php
  2. +1 βˆ’1 tests/RunnerOutput/OutputHandlers.expect.jUnit.xml
@@ -67,7 +67,7 @@ public function end()
$time = sprintf('%0.1f', microtime(true) - $this->startTime);
$output = $this->buffer;
$results = $this->runner->getResults();
$this->buffer = "\t<testsuite errors=\"{$results[3]}\" skipped=\"{$results[2]}\" tests=\"" . array_sum($results) . "\" time=\"$time\" timestamp=\"" . @date('Y-m-d\TH:i:s') . "\">\n";
$this->buffer = "\t<testsuite errors=\"{$results[Test::FAILED]}\" skipped=\"{$results[Test::SKIPPED]}\" tests=\"" . array_sum($results) . "\" time=\"$time\" timestamp=\"" . @date('Y-m-d\TH:i:s') . "\">\n";
$this->buffer .= $output;
$this->buffer .= "\t</testsuite>";
@@ -1,6 +1,6 @@
<?xml version="1.0" encoding="UTF-8"?>
<testsuites>
<testsuite errors="4" skipped="3" tests="11" time="%a%" timestamp="%a%">
<testsuite errors="4" skipped="4" tests="11" time="%a%" timestamp="%a%">
<testcase classname="%a%01-basic.fail.phptx" name="%a%01-basic.fail.phptx">
<failure message="Multi
line

0 comments on commit 900febd

Please sign in to comment.