function HtmlRenderer::render
@psalm-param array<string, TestResultCollection> $tests
File
-
vendor/
phpunit/ phpunit/ src/ Logging/ TestDox/ HtmlRenderer.php, line 109
Class
- HtmlRenderer
- @no-named-arguments Parameter names are not covered by the backward compatibility promise for PHPUnit
Namespace
PHPUnit\Logging\TestDoxCode
public function render(array $tests) : string {
$buffer = self::PAGE_HEADER;
foreach ($tests as $prettifiedClassName => $_tests) {
$buffer .= sprintf(self::CLASS_HEADER, $prettifiedClassName);
foreach ($this->reduce($_tests) as $prettifiedMethodName => $outcome) {
$buffer .= sprintf(" <li class=\"%s\">%s</li>\n", $outcome, $prettifiedMethodName);
}
$buffer .= self::CLASS_FOOTER;
}
return $buffer . self::PAGE_FOOTER;
}