Open ISErikMeijer opened 10 months ago
That would be indeed beneficial. Sadly, mutation coverage is very poor proxy for code coverage as it focuses on where Stryker injected mutations with no concern about non mutated code. Furthermore, we capture coverage for a mutated version of the project, not the original one. As such: 1) metrics would be wrong as Stryker adds to the code base 2) coverage could be wrong (in subtle way) for some test/mutated code interferences.
In short, this is an interesting objective, but I do not see this happening in a near or medium future
that being said, the mutation coverage data can be published. But, again, this is a different report.
We might be able to reuse the coverlet collector https://github.com/coverlet-coverage/coverlet/blob/master/src/coverlet.collector/DataCollection/CoverletCoverageCollector.cs
We could capture code coverage as part of the initial test run (that could be used as a normal test run BTW), but no use benefit beyond that. I am probably missing something important, but:
There are also significant hurdle to address
@dupdob I don't think we need to use the coverage information to determine mutant coverage. We can keep that like it is. We just need to add coverage analysis to the initial testrun and get the percentage from it. The initial testrun doesn't contain mutations so the coverage should be correct.
oh, ok. I feel better then :-)
If possible I would like if it showed the normal overall code coverage in the final stryker report, so I don't have to separately run a code coverage test.