Skip to content

Commit 9eae272

Browse files
committed
show 100% when the total line, branch or methods covered is 0
1 parent 820a450 commit 9eae272

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/coverlet.core/CoverageDetails.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ public class CoverageDetails
88
public int Total { get; internal set; }
99
public double Percent
1010
{
11-
get => Math.Round(Total == 0 ? Total : Covered / Total, 3);
11+
get => Math.Round(Total == 0 ? 1 : Covered / Total, 3);
1212
}
1313
}
1414
}

0 commit comments

Comments
 (0)