protected function PHPUnit_TextUI_ResultPrinter::printDefects in Zircon Profile 8
Same name and namespace in other branches
- 8.0 vendor/phpunit/phpunit/src/TextUI/ResultPrinter.php \PHPUnit_TextUI_ResultPrinter::printDefects()
Parameters
array $defects:
string $type:
5 calls to PHPUnit_TextUI_ResultPrinter::printDefects()
- PHPUnit_TextUI_ResultPrinter::printErrors in vendor/
phpunit/ phpunit/ src/ TextUI/ ResultPrinter.php - PHPUnit_TextUI_ResultPrinter::printFailures in vendor/
phpunit/ phpunit/ src/ TextUI/ ResultPrinter.php - PHPUnit_TextUI_ResultPrinter::printIncompletes in vendor/
phpunit/ phpunit/ src/ TextUI/ ResultPrinter.php - PHPUnit_TextUI_ResultPrinter::printRisky in vendor/
phpunit/ phpunit/ src/ TextUI/ ResultPrinter.php - @since Method available since Release 4.0.0
- PHPUnit_TextUI_ResultPrinter::printSkipped in vendor/
phpunit/ phpunit/ src/ TextUI/ ResultPrinter.php - @since Method available since Release 3.0.0
File
- vendor/
phpunit/ phpunit/ src/ TextUI/ ResultPrinter.php, line 212
Class
- PHPUnit_TextUI_ResultPrinter
- Prints the result of a TextUI TestRunner run.
Code
protected function printDefects(array $defects, $type) {
$count = count($defects);
if ($count == 0) {
return;
}
$this
->write(sprintf("There %s %d %s%s:\n", $count == 1 ? 'was' : 'were', $count, $type, $count == 1 ? '' : 's'));
$i = 1;
foreach ($defects as $defect) {
$this
->printDefect($defect, $i++);
}
}