public function PHPUnit_Util_TestDox_ResultPrinter::endTest

A test ended.

Parameters

PHPUnit_Framework_Test $test:

float $time:

Overrides PHPUnit_Framework_TestListener::endTest

File

drupal/core/vendor/phpunit/phpunit/PHPUnit/Util/TestDox/ResultPrinter.php, line 268

Class

PHPUnit_Util_TestDox_ResultPrinter
Base class for printers of TestDox documentation.

Code

public function endTest(PHPUnit_Framework_Test $test, $time) {
  if ($test instanceof $this->testTypeOfInterest) {
    if (!isset($this->tests[$this->currentTestMethodPrettified])) {
      if ($this->testStatus == PHPUnit_Runner_BaseTestRunner::STATUS_PASSED) {
        $this->tests[$this->currentTestMethodPrettified]['success'] = 1;
        $this->tests[$this->currentTestMethodPrettified]['failure'] = 0;
      }
      else {
        $this->tests[$this->currentTestMethodPrettified]['success'] = 0;
        $this->tests[$this->currentTestMethodPrettified]['failure'] = 1;
      }
    }
    else {
      if ($this->testStatus == PHPUnit_Runner_BaseTestRunner::STATUS_PASSED) {
        $this->tests[$this->currentTestMethodPrettified]['success']++;
      }
      else {
        $this->tests[$this->currentTestMethodPrettified]['failure']++;
      }
    }
    $this->currentTestClassPrettified = NULL;
    $this->currentTestMethodPrettified = NULL;
  }
}