Skip to content

Commit

Permalink
Consider no lines a valid input, (#73)
Browse files Browse the repository at this point in the history
and output a valid result.

Fixes #72
  • Loading branch information
tomalec committed Aug 29, 2022
1 parent cdda0be commit 8177a53
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/functions.php
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,12 @@ function handleOutput(array $lines, float $minimumPercentCovered, Output $output

if ($coveredLines + $uncoveredLines == 0) {
error_log('No lines found!');

$output->output(
$lines['uncoveredLines'],
100,
$minimumPercentCovered
);
return;
}

Expand Down

0 comments on commit 8177a53

Please sign in to comment.