SlatherOrg / slather

Generate test coverage reports for Xcode projects & hook it into CI.
MIT License
1.55k stars 236 forks source link

Add relevant lines count and tested lines count to html report #494

Closed SiemianHS closed 3 years ago

SiemianHS commented 3 years ago

Background story

In the project where multiple modules are created, having just the code coverage percentage per module is not enough information to calculate the overall code coverage for the whole project. Additional information about total number of lines and total number of lines tested is required.

PR description

In this PR additional data regarding total number of lines and total number of lines tested is added to html report.

Screen shot

Zrzut ekranu 2021-04-24 o 11 21 10
coveralls commented 3 years ago

Coverage Status

Coverage increased (+0.02%) to 96.253% when pulling 2c6066cc2de2dd749377d77838a66c56b3176190 on SiemianHS:master into 9f355965d01c3d0174edf955c1f977f8214f34d9 on SlatherOrg:master.

ksuther commented 3 years ago

Thanks for the PR! Since this is showing the count for Total Coverage, would it make more sense to put the line count on the same line as Total Coverage?

For example, something like:

Total Coverage : 94.37% (218 of 231 lines)

SiemianHS commented 3 years ago

Why i have not thought of that? 🤔 Great suggestion, thanks @ksuther. I will apply it.

SiemianHS commented 3 years ago

Updated according to your suggestion @ksuther, thank you for it and for all the hard work on Slather.

Zrzut ekranu 2021-04-29 o 15 52 10
ksuther commented 3 years ago

Thanks for the change! The bad news is you flipped the order of the variables. It should be 218 of 231 :)

SiemianHS commented 3 years ago

Shame on me, looks like i had some kind of brain fart when writing this. Thanks for spotting the issue. Now it's fixed.

ksuther commented 3 years ago

Thanks for the PR!