mirror of
https://github.com/pestphp/pest.git
synced 2026-04-21 22:47:27 +02:00
just in case
This commit is contained in:
@ -93,8 +93,16 @@ final class Coverage
|
|||||||
$codeCoverage = require $reportPath;
|
$codeCoverage = require $reportPath;
|
||||||
unlink($reportPath);
|
unlink($reportPath);
|
||||||
|
|
||||||
$facade = Facade::fromSerializedData($codeCoverage);
|
if (is_array($codeCoverage)) {
|
||||||
$report = (fn (): Directory => $this->report)->call($facade);
|
/** @var Facade $test */
|
||||||
|
$facade = Facade::fromSerializedData($codeCoverage);
|
||||||
|
|
||||||
|
/** @var Directory<File|Directory> $report */
|
||||||
|
$report = (fn () => $this->report)->call($facade);
|
||||||
|
} else {
|
||||||
|
/** @var Directory<File|Directory> $report */
|
||||||
|
$report = $codeCoverage->getReport();
|
||||||
|
}
|
||||||
|
|
||||||
$totalCoverage = $report->percentageOfExecutedLines();
|
$totalCoverage = $report->percentageOfExecutedLines();
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user