mirror of
https://github.com/pestphp/pest.git
synced 2026-03-06 15:57:21 +01:00
25 lines
566 B
PHP
25 lines
566 B
PHP
<?php
|
|
|
|
use Pest\Console\Coverage;
|
|
|
|
it('generates coverage based on file input', function () {
|
|
assertEquals([
|
|
'4..6', '102',
|
|
], Coverage::getMissingCoverage(new class() {
|
|
public function getCoverageData(): array
|
|
{
|
|
return [
|
|
1 => ['foo'],
|
|
2 => ['bar'],
|
|
4 => [],
|
|
5 => [],
|
|
6 => [],
|
|
7 => null,
|
|
100 => null,
|
|
101 => ['foo'],
|
|
102 => [],
|
|
];
|
|
}
|
|
}));
|
|
});
|