paintFail() public method

Paints the test failure as a stack trace.
public paintFail ( string $message )
$message string Failure message displayed in the context of the other tests.
 function paintFail($message)
 {
     parent::paintFail($message);
     $this->failed_tests[] = '[FLR] ' . $this->_extractErrorFileAndLine($message);
 }
Example #2
0
 /**
  * Paint fail faildetail to STDERR.
  */
 function paintFail($message)
 {
     parent::paintFail($message);
     fwrite(STDERR, 'FAIL' . $this->faildetail_separator . $this->_paintTestFailDetail($message));
 }
Example #3
0
 function paintFail($message) {
     parent::paintFail($message);
     $breadcrumb = $this->getTestList();
     array_shift($breadcrumb);
     $out = '';
     $out.= implode(" -> ", $breadcrumb);
     $out.= " -> " . $message . "\n";
     $this->fail_messages[] = $out;
     if (!isset($this->_failCounts[$this->suiteName])) {
         $this->_failCounts[$this->suiteName] = 0;
     }
     if (!isset($this->_failCounts[$this->testFileName])) {
         $this->_failCounts[$this->testFileName] = 0;
     }
     if (!isset($this->_failCounts[$this->testMethodName])) {
         $this->_failCounts[$this->testMethodName] = 0;
     }
     $this->_failCounts[$this->testMethodName]++;
     $this->_failCounts[$this->testFileName]++;
     $this->_failCounts[$this->suiteName]++;
 }