Skip to content

Commit d958cc6

Browse files
B#187800 PHPFCI: warning when custom coverage is above or equal to global coverage
1 parent 434e41b commit d958cc6

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/Lib/Metrics/Inspection/CustomCoverageAboveGlobalInspection.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ public function inspect(?PathInspectionConfig $fileConfig, FileMetric $metric):
2424
$customCoverage = $fileConfig->getMinimumCoverage();
2525

2626
// custom coverage is lower than global coverage, and file is above global coverage
27-
if ($customCoverage < $globalCoverage && $metric->getCoverage() >= $globalCoverage) {
27+
if ($customCoverage <= $globalCoverage && $metric->getCoverage() >= $globalCoverage) {
2828
return new Failure($metric, $fileConfig->getMinimumCoverage(), Failure::UNNECESSARY_CUSTOM_COVERAGE);
2929
}
3030

0 commit comments

Comments
 (0)