com phpruntests: update outputWriter - extended xml-output: src/testcase/output/rtTestOutputWriterCSV.php
src/testcase/output/rtTestOutputWriterList.php src/testcase/output/rtTestOutputWriterXML.php src/testcase/rtTestOutputWriter.php
src/testcase/rtTestResults.php src/testcase/rtTestStatus.php
| From: | David Soria Parra | Date: | Wed, 15 Jul 2009 21:44:54 +0000 |
| Subject: | com phpruntests: update outputWriter - extended xml-output: src/testcase/output/rtTestOutputWriterCSV.php src/testcase/output/rtTestOutputWriterList.php src/testcase/output/rtTestOutputWriterXML.php src/testcase/rtTestOutputWriter.php src/testcase/rtTestResults.php src/testcase/rtTestStatus.php |
||
| Groups: | php.qa | ||
| Request: | Send a blank email to php-qa+get-66335@lists.php.net to get a copy of this message | ||
Commit: e46728fd70b58e6b9c3d6fe01ad978155b525dcd
Author: Georg Gradwohl <g2@php.net> Wed, 15 Jul 2009 21:44:54 +0000
Parents: f86c2b82fa29cc63a0cd3625193e8956b64c0b54
Branches: master
Link: http://git.php.net/?p=phpruntests.git;a=commitdiff;h=e46728fd70b58e6b9c3d6fe01ad978155b525dcd
Log:
update outputWriter - extended xml-output
Changed paths:
M src/testcase/output/rtTestOutputWriterCSV.php
M src/testcase/output/rtTestOutputWriterList.php
M src/testcase/output/rtTestOutputWriterXML.php
M src/testcase/rtTestOutputWriter.php
M src/testcase/rtTestResults.php
M src/testcase/rtTestStatus.php
diff --git a/src/testcase/output/rtTestOutputWriterCSV.php b/src/testcase/output/rtTestOutputWriterCSV.php index 401f541..725dc81 100644 --- a/src/testcase/output/rtTestOutputWriterCSV.php +++ b/src/testcase/output/rtTestOutputWriterCSV.php @@ -25,16 +25,21 @@ class rtTestOutputWriterCSV extends rtTestOutputWriter public function createOutput() { - foreach ($this->resultList as $testResult) { - $outputString = $testResult->getName(); - $testStatus = $testResult->getStatus(); - foreach($testStatus->getTestStateNames() as $name) { - if($testStatus->getValue($name)) { - $outputString .= " , ". strtoupper($name); - - } - } - $this->output .= $outputString."\n"; + foreach ($this->resultList as $testGroupResults) { + + foreach ($testGroupResults as $testResult) { + + $outputString = $testResult->getName(); + $testStatus = $testResult->getStatus(); + + foreach($testStatus->getTestStateNames() as $name) { + + if($testStatus->getValue($name)) { + $outputString .= " , ". strtoupper($name); + } + } + $this->output .= $outputString."\n"; + } } } diff --git a/src/testcase/output/rtTestOutputWriterList.php b/src/testcase/output/rtTestOutputWriterList.php index 6da6869..27e0b0b 100644 --- a/src/testcase/output/rtTestOutputWriterList.php +++ b/src/testcase/output/rtTestOutputWriterList.php @@ -24,20 +24,27 @@ class rtTestOutputWriterList extends rtTestOutputWriter public function createOutput() { - foreach ($this->resultList as $testResult) { - $outputString = ""; - $testStatus = $testResult->getStatus(); - foreach($testStatus->getTestStateNames() as $name) { - if($testStatus->getValue($name)) { - $outputString .= " ". strtoupper($name); - $outputString .= " " . $testStatus->getMessage($name); - } - } - $outputString .= " " . $testResult->getTitle(); - $outputString .= " [" . $testResult->getName() . ".phpt]"; - $this->output .= $outputString."\n"; + foreach ($this->resultList as $testGroupResults) { + + foreach ($testGroupResults as $testResult) { + + $outputString = ""; + $testStatus = $testResult->getStatus(); + + foreach($testStatus->getTestStateNames() as $name) { + + if ($testStatus->getValue($name)) { + $outputString .= " ". strtoupper($name); + $outputString .= " " . $testStatus->getMessage($name); + } + } + + $outputString .= " " . $testResult->getTitle(); + $outputString .= " [" . $testResult->getName() . ".phpt]"; + $this->output .= $outputString."\n"; + } } } } -?> +?> \ No newline at end of file diff --git a/src/testcase/output/rtTestOutputWriterXML.php b/src/testcase/output/rtTestOutputWriterXML.php index 9311565..821f8cd 100644 --- a/src/testcase/output/rtTestOutputWriterXML.php +++ b/src/testcase/output/rtTestOutputWriterXML.php @@ -38,14 +38,97 @@ class rtTestOutputWriterXML extends rtTestOutputWriter */ public function createOutput() { - foreach ($this->resultList as $result) { + $wdir = getcwd(); + + $global_state = array(); + $global_count = 0; + + foreach ($this->resultList as $testGroupResults) { + + // creat group-node + $groupNode = $this->dom->createElement('testgroup'); + $this->rootNode->appendChild($groupNode); + + $state = array(); + + foreach ($testGroupResults as $testResult) { + + // create test-node + $testNode = $this->dom->createElement('testcase'); + $groupNode->appendChild($testNode); + + // name + $n = explode($wdir, $testResult->getName()); + $n = explode('/', $n[1]); + $n = array_pop($n); + $testNode->setAttribute('name', $n); + + // status + $status = $testResult->getStatus(); + $s = $status->__toString(); + $testNode->setAttribute('status', strtoupper($s)); + + // title + $title = $testResult->getTitle(); + + if (strlen($title) > 0) { + $titleNode = $this->dom->createElement('title', utf8_encode(htmlentities($title))); + $testNode->appendChild($titleNode); + } + + // message + $msg = $status->getMessage($s); + + if (!is_null($msg)) { + $msgNode = $this->dom->createElement('message', utf8_encode(htmlentities($msg))); + $testNode->appendChild($msgNode); + } + + // files + $files = $testResult->getSavedFileNames(); + + if (sizeof($files) > 0) { + + $fileNode = $this->dom->createElement('files'); + $testNode->appendChild($fileNode); + + foreach ($files as $type => $file) { + $fileNode->setAttribute($type, $file); + } + } + + // count + if (!isset($state[$s])) { + $state[$s] = 0; + $global_state[$s] = 0; + } + + $state[$s]++; + $global_state[$s]++; + } + + $global_count += sizeof($testGroupResults); + + // add group-node attributes - $test = $this->dom->createElement('testcase'); - $test->appendChild($this->dom->createElement('name', $result->getName())); - $test->appendChild($this->dom->createElement('status', $result->getStatus())); - $this->rootNode->appendChild($test); - } + $n = explode($wdir, $testGroupResults[0]->getName()); + $n = explode('/', $n[1]); + array_pop($n); + $n = implode('/', $n); + + $groupNode->setAttribute('name', $n); + $groupNode->setAttribute('tests', sizeof($testGroupResults)); + + $time = round($testGroupResults[0]->getTime(), 2); + $groupNode->setAttribute('time', $time); + + foreach ($state as $k => $v) { + $groupNode->setAttribute($k, $v); + } + } + $this->dom->formatOutput = true; + $this->dom->normalizeDocument(); $this->output = $this->dom->saveXML(); } diff --git a/src/testcase/rtTestOutputWriter.php b/src/testcase/rtTestOutputWriter.php index e9173a8..699b450 100644 --- a/src/testcase/rtTestOutputWriter.php +++ b/src/testcase/rtTestOutputWriter.php @@ -2,8 +2,7 @@ /** * rtTestOutputWriter * - * Writes test output. This is concerned with status (PASS, FAIL etc) not - * with the log files. + * Writes test output. * * @category Testing * @package RUNTESTS @@ -20,9 +19,7 @@ abstract class rtTestOutputWriter protected $output = NULL; protected $type = 'list'; protected $overview = NULL; - - const OUTPUT_DIR = 'results'; - + public static function getInstance($type='list') { @@ -34,7 +31,7 @@ abstract class rtTestOutputWriter break; case 'html': - + return new rtTestOutputWriterHTML(); break; case 'csv': @@ -46,42 +43,43 @@ abstract class rtTestOutputWriter case 'txt': return new rtTestOutputWriterList(); break; - } } + - + /** + * + * @param array $resultList an array of arrays (testgroups) of rtTestResults + */ public function setResultList(array $resultList) { $this->resultList = $resultList; } - - - /** - * - */ + /** + * + * @return string $output + */ public function getOutput() { return $this->output; } - - - + + /** + * writes the the results to a file + * + * @param $filename + */ public function write($filename=null) { $this->createOutput(); if (!is_null($this->output)) { - - if (!file_exists(self::OUTPUT_DIR)) { - mkdir(self::OUTPUT_DIR); - } if (is_null($filename)) { - $filename = self::OUTPUT_DIR.'/results_'.round(microtime(true)).'.'.$this->type; + $filename = 'results_'.round(microtime(true)).'.'.$this->type; } if (file_put_contents($filename, $this->output)) { @@ -93,6 +91,13 @@ abstract class rtTestOutputWriter } + /** + * creates an overview about the test-results + * + * @param integer $groups + * @param integer $processCount + * @return string + */ public function getOverview($groups=NULL, $processCount=NULL) { // if the overview was already created retun it @@ -104,16 +109,19 @@ abstract class rtTestOutputWriter $state = array(); $count = 0; - foreach ($this->resultList as $result) { + foreach ($this->resultList as $testGroupResults) { + + foreach ($testGroupResults as $testResult) { - $s = $result->getStatus()->__toString(); - - if (!isset($state[$s])) { - $state[$s] = 0; - } - - $state[$s]++; - $count++; + $s = $testResult->getStatus()->__toString(); + + if (!isset($state[$s])) { + $state[$s] = 0; + } + + $state[$s]++; + $count++; + } } // create the output-string @@ -153,11 +161,11 @@ abstract class rtTestOutputWriter $str .= ' '; } - $str .= $v; + $str .= $v.' '; $p = round($v/$count*100,2); - $blanks = 5-strlen($v); + $blanks = 5-strlen($p); for ($b=0; $b<$blanks; $b++) { $str .= ' '; } @@ -180,7 +188,13 @@ abstract class rtTestOutputWriter } - + /** + * prints out the results of a testgroup + * + * @param array $results + * @param $state + * @param $cid + */ public static function flushResult(array $results, $state=0, $cid=NULL) { switch ($state) { @@ -189,7 +203,6 @@ abstract class rtTestOutputWriter return; break; - default: case 0: // a dot per test-case @@ -198,7 +211,6 @@ abstract class rtTestOutputWriter } break; - case 1: // every test-case incl. status print "\n"; foreach ($results as $result) { @@ -206,7 +218,6 @@ abstract class rtTestOutputWriter } break; - case 2: // details about not-passed tests foreach ($results as $result) { @@ -221,15 +232,19 @@ abstract class rtTestOutputWriter print strtoupper($name)."\t".$result->getName()."\n"; if ($name !== 'pass') { - print "desc:\t".$result->getTitle()."\n"; - print "msg:\t".$s->getMessage($name)."\n"; + print "DESC:\t".$result->getTitle()."\n"; + + $msg = $s->getMessage($name); + if (!is_null($msg)) { + print "MSG:\t".$msg."\n"; + } + print "\n"; } } break; - case 3: // all available details foreach ($results as $result) { @@ -239,31 +254,30 @@ abstract class rtTestOutputWriter print "\n"; print strtoupper($name)."\t".$result->getName()."\n"; - print "desc:\t".$result->getTitle()."\n"; - print "msg:\t".$s->getMessage($name)."\n"; + print "DESC:\t".$result->getTitle()."\n"; + + $msg = $s->getMessage($name); + + if (!is_null($msg)) { + print "MSG:\t".$msg."\n"; + } if (!is_null($cid)) { print "CID:\t$cid\n"; } - - print "mem:\t".round(memory_get_usage()/1024, 2)." kB\n"; + + print "MEM:\t".round(memory_get_usage()/1024, 2)." kB\n"; $files = $result->getSavedFileNames(); if (sizeof($files) > 0) { - print "files:\t"; - - foreach ($files as $file) { - print $file.', '; + print "FILES:\n"; + foreach ($files as $t => $file) { + print "$t:\t$file\n"; } - - print "\n"; } - - } - break; } @@ -272,4 +286,4 @@ abstract class rtTestOutputWriter } -?> +?> \ No newline at end of file diff --git a/src/testcase/rtTestResults.php b/src/testcase/rtTestResults.php index b7bc4a7..a65dd77 100644 --- a/src/testcase/rtTestResults.php +++ b/src/testcase/rtTestResults.php @@ -23,6 +23,7 @@ class rtTestResults private $testName = ''; private $savedFileNames = array(); private $title = ''; + private $time = 0; public function __construct(rtPhpTest $testCase = null, rtTestStatus $testStatus = null) { @@ -166,5 +167,15 @@ class rtTestResults { return $this->title; } + + public function getTime() + { + return $this->time; + } + + public function setTime($time) + { + $this->time = $time; + } } ?> diff --git a/src/testcase/rtTestStatus.php b/src/testcase/rtTestStatus.php index 759b31e..997beec 100644 --- a/src/testcase/rtTestStatus.php +++ b/src/testcase/rtTestStatus.php @@ -39,7 +39,7 @@ class rtTestStatus { { foreach ($this->testStateNames as $name) { $this->states[$name] = false; - $this->messages[$name] = '-- none --'; + $this->messages[$name] = null; } }
diff --git a/src/testcase/output/rtTestOutputWriterCSV.php b/src/testcase/output/rtTestOutputWriterCSV.php index 401f541..725dc81 100644 --- a/src/testcase/output/rtTestOutputWriterCSV.php +++ b/src/testcase/output/rtTestOutputWriterCSV.php @@ -25,16 +25,21 @@ class rtTestOutputWriterCSV extends rtTestOutputWriter public function createOutput() { - foreach ($this->resultList as $testResult) { - $outputString = $testResult->getName(); - $testStatus = $testResult->getStatus(); - foreach($testStatus->getTestStateNames() as $name) { - if($testStatus->getValue($name)) { - $outputString .= " , ". strtoupper($name); - - } - } - $this->output .= $outputString."\n"; + foreach ($this->resultList as $testGroupResults) { + + foreach ($testGroupResults as $testResult) { + + $outputString = $testResult->getName(); + $testStatus = $testResult->getStatus(); + + foreach($testStatus->getTestStateNames() as $name) { + + if($testStatus->getValue($name)) { + $outputString .= " , ". strtoupper($name); + } + } + $this->output .= $outputString."\n"; + } } } diff --git a/src/testcase/output/rtTestOutputWriterList.php b/src/testcase/output/rtTestOutputWriterList.php index 6da6869..27e0b0b 100644 --- a/src/testcase/output/rtTestOutputWriterList.php +++ b/src/testcase/output/rtTestOutputWriterList.php @@ -24,20 +24,27 @@ class rtTestOutputWriterList extends rtTestOutputWriter public function createOutput() { - foreach ($this->resultList as $testResult) { - $outputString = ""; - $testStatus = $testResult->getStatus(); - foreach($testStatus->getTestStateNames() as $name) { - if($testStatus->getValue($name)) { - $outputString .= " ". strtoupper($name); - $outputString .= " " . $testStatus->getMessage($name); - } - } - $outputString .= " " . $testResult->getTitle(); - $outputString .= " [" . $testResult->getName() . ".phpt]"; - $this->output .= $outputString."\n"; + foreach ($this->resultList as $testGroupResults) { + + foreach ($testGroupResults as $testResult) { + + $outputString = ""; + $testStatus = $testResult->getStatus(); + + foreach($testStatus->getTestStateNames() as $name) { + + if ($testStatus->getValue($name)) { + $outputString .= " ". strtoupper($name); + $outputString .= " " . $testStatus->getMessage($name); + } + } + + $outputString .= " " . $testResult->getTitle(); + $outputString .= " [" . $testResult->getName() . ".phpt]"; + $this->output .= $outputString."\n"; + } } } } -?> +?> \ No newline at end of file diff --git a/src/testcase/output/rtTestOutputWriterXML.php b/src/testcase/output/rtTestOutputWriterXML.php index 9311565..821f8cd 100644 --- a/src/testcase/output/rtTestOutputWriterXML.php +++ b/src/testcase/output/rtTestOutputWriterXML.php @@ -38,14 +38,97 @@ class rtTestOutputWriterXML extends rtTestOutputWriter */ public function createOutput() { - foreach ($this->resultList as $result) { + $wdir = getcwd(); + + $global_state = array(); + $global_count = 0; + + foreach ($this->resultList as $testGroupResults) { + + // creat group-node + $groupNode = $this->dom->createElement('testgroup'); + $this->rootNode->appendChild($groupNode); + + $state = array(); + + foreach ($testGroupResults as $testResult) { + + // create test-node + $testNode = $this->dom->createElement('testcase'); + $groupNode->appendChild($testNode); + + // name + $n = explode($wdir, $testResult->getName()); + $n = explode('/', $n[1]); + $n = array_pop($n); + $testNode->setAttribute('name', $n); + + // status + $status = $testResult->getStatus(); + $s = $status->__toString(); + $testNode->setAttribute('status', strtoupper($s)); + + // title + $title = $testResult->getTitle(); + + if (strlen($title) > 0) { + $titleNode = $this->dom->createElement('title', utf8_encode(htmlentities($title))); + $testNode->appendChild($titleNode); + } + + // message + $msg = $status->getMessage($s); + + if (!is_null($msg)) { + $msgNode = $this->dom->createElement('message', utf8_encode(htmlentities($msg))); + $testNode->appendChild($msgNode); + } + + // files + $files = $testResult->getSavedFileNames(); + + if (sizeof($files) > 0) { + + $fileNode = $this->dom->createElement('files'); + $testNode->appendChild($fileNode); + + foreach ($files as $type => $file) { + $fileNode->setAttribute($type, $file); + } + } + + // count + if (!isset($state[$s])) { + $state[$s] = 0; + $global_state[$s] = 0; + } + + $state[$s]++; + $global_state[$s]++; + } + + $global_count += sizeof($testGroupResults); + + // add group-node attributes - $test = $this->dom->createElement('testcase'); - $test->appendChild($this->dom->createElement('name', $result->getName())); - $test->appendChild($this->dom->createElement('status', $result->getStatus())); - $this->rootNode->appendChild($test); - } + $n = explode($wdir, $testGroupResults[0]->getName()); + $n = explode('/', $n[1]); + array_pop($n); + $n = implode('/', $n); + + $groupNode->setAttribute('name', $n); + $groupNode->setAttribute('tests', sizeof($testGroupResults)); + + $time = round($testGroupResults[0]->getTime(), 2); + $groupNode->setAttribute('time', $time); + + foreach ($state as $k => $v) { + $groupNode->setAttribute($k, $v); + } + } + $this->dom->formatOutput = true; + $this->dom->normalizeDocument(); $this->output = $this->dom->saveXML(); } diff --git a/src/testcase/rtTestOutputWriter.php b/src/testcase/rtTestOutputWriter.php index e9173a8..699b450 100644 --- a/src/testcase/rtTestOutputWriter.php +++ b/src/testcase/rtTestOutputWriter.php @@ -2,8 +2,7 @@ /** * rtTestOutputWriter * - * Writes test output. This is concerned with status (PASS, FAIL etc) not - * with the log files. + * Writes test output. * * @category Testing * @package RUNTESTS @@ -20,9 +19,7 @@ abstract class rtTestOutputWriter protected $output = NULL; protected $type = 'list'; protected $overview = NULL; - - const OUTPUT_DIR = 'results'; - + public static function getInstance($type='list') { @@ -34,7 +31,7 @@ abstract class rtTestOutputWriter break; case 'html': - + return new rtTestOutputWriterHTML(); break; case 'csv': @@ -46,42 +43,43 @@ abstract class rtTestOutputWriter case 'txt': return new rtTestOutputWriterList(); break; - } } + - + /** + * + * @param array $resultList an array of arrays (testgroups) of rtTestResults + */ public function setResultList(array $resultList) { $this->resultList = $resultList; } - - - /** - * - */ + /** + * + * @return string $output + */ public function getOutput() { return $this->output; } - - - + + /** + * writes the the results to a file + * + * @param $filename + */ public function write($filename=null) { $this->createOutput(); if (!is_null($this->output)) { - - if (!file_exists(self::OUTPUT_DIR)) { - mkdir(self::OUTPUT_DIR); - } if (is_null($filename)) { - $filename = self::OUTPUT_DIR.'/results_'.round(microtime(true)).'.'.$this->type; + $filename = 'results_'.round(microtime(true)).'.'.$this->type; } if (file_put_contents($filename, $this->output)) { @@ -93,6 +91,13 @@ abstract class rtTestOutputWriter } + /** + * creates an overview about the test-results + * + * @param integer $groups + * @param integer $processCount + * @return string + */ public function getOverview($groups=NULL, $processCount=NULL) { // if the overview was already created retun it @@ -104,16 +109,19 @@ abstract class rtTestOutputWriter $state = array(); $count = 0; - foreach ($this->resultList as $result) { + foreach ($this->resultList as $testGroupResults) { + + foreach ($testGroupResults as $testResult) { - $s = $result->getStatus()->__toString(); - - if (!isset($state[$s])) { - $state[$s] = 0; - } - - $state[$s]++; - $count++; + $s = $testResult->getStatus()->__toString(); + + if (!isset($state[$s])) { + $state[$s] = 0; + } + + $state[$s]++; + $count++; + } } // create the output-string @@ -153,11 +161,11 @@ abstract class rtTestOutputWriter $str .= ' '; } - $str .= $v; + $str .= $v.' '; $p = round($v/$count*100,2); - $blanks = 5-strlen($v); + $blanks = 5-strlen($p); for ($b=0; $b<$blanks; $b++) { $str .= ' '; } @@ -180,7 +188,13 @@ abstract class rtTestOutputWriter } - + /** + * prints out the results of a testgroup + * + * @param array $results + * @param $state + * @param $cid + */ public static function flushResult(array $results, $state=0, $cid=NULL) { switch ($state) { @@ -189,7 +203,6 @@ abstract class rtTestOutputWriter return; break; - default: case 0: // a dot per test-case @@ -198,7 +211,6 @@ abstract class rtTestOutputWriter } break; - case 1: // every test-case incl. status print "\n"; foreach ($results as $result) { @@ -206,7 +218,6 @@ abstract class rtTestOutputWriter } break; - case 2: // details about not-passed tests foreach ($results as $result) { @@ -221,15 +232,19 @@ abstract class rtTestOutputWriter print strtoupper($name)."\t".$result->getName()."\n"; if ($name !== 'pass') { - print "desc:\t".$result->getTitle()."\n"; - print "msg:\t".$s->getMessage($name)."\n"; + print "DESC:\t".$result->getTitle()."\n"; + + $msg = $s->getMessage($name); + if (!is_null($msg)) { + print "MSG:\t".$msg."\n"; + } + print "\n"; } } break; - case 3: // all available details foreach ($results as $result) { @@ -239,31 +254,30 @@ abstract class rtTestOutputWriter print "\n"; print strtoupper($name)."\t".$result->getName()."\n"; - print "desc:\t".$result->getTitle()."\n"; - print "msg:\t".$s->getMessage($name)."\n"; + print "DESC:\t".$result->getTitle()."\n"; + + $msg = $s->getMessage($name); + + if (!is_null($msg)) { + print "MSG:\t".$msg."\n"; + } if (!is_null($cid)) { print "CID:\t$cid\n"; } - - print "mem:\t".round(memory_get_usage()/1024, 2)." kB\n"; + + print "MEM:\t".round(memory_get_usage()/1024, 2)." kB\n"; $files = $result->getSavedFileNames(); if (sizeof($files) > 0) { - print "files:\t"; - - foreach ($files as $file) { - print $file.', '; + print "FILES:\n"; + foreach ($files as $t => $file) { + print "$t:\t$file\n"; } - - print "\n"; } - - } - break; } @@ -272,4 +286,4 @@ abstract class rtTestOutputWriter } -?> +?> \ No newline at end of file diff --git a/src/testcase/rtTestResults.php b/src/testcase/rtTestResults.php index b7bc4a7..a65dd77 100644 --- a/src/testcase/rtTestResults.php +++ b/src/testcase/rtTestResults.php @@ -23,6 +23,7 @@ class rtTestResults private $testName = ''; private $savedFileNames = array(); private $title = ''; + private $time = 0; public function __construct(rtPhpTest $testCase = null, rtTestStatus $testStatus = null) { @@ -166,5 +167,15 @@ class rtTestResults { return $this->title; } + + public function getTime() + { + return $this->time; + } + + public function setTime($time) + { + $this->time = $time; + } } ?> diff --git a/src/testcase/rtTestStatus.php b/src/testcase/rtTestStatus.php index 759b31e..997beec 100644 --- a/src/testcase/rtTestStatus.php +++ b/src/testcase/rtTestStatus.php @@ -39,7 +39,7 @@ class rtTestStatus { { foreach ($this->testStateNames as $name) { $this->states[$name] = false; - $this->messages[$name] = '-- none --'; + $this->messages[$name] = null; } }