[X] I have verified this is the correct repository for opening this issue.
[X] I have verified no other issues exist related to my problem.
[X] I have verified this is not an issue for a specific package.
[X] I have verified this issue is not security related.
[X] I confirm I am using official, and not unofficial, or modified, Chocolatey products.
What You Are Seeing?
When running the build.bat on a project that is configured to use Coverlet (via the inclusion of the Coverlet NuGet package) Coverlet is not being used, but instead OpenCover is being used. This should not happen.
The problem here is that an invalid check for IsNetCore() is being used, which mean that usage of Coverlet is never allowed. There is a known issue with the IsNetCore() method, where is doesn't correctly detect anything above .NET 5.0, and shouldn't be used.
What is Expected?
When a project is configured to use Coverlet via the NuGet package, unit test coverage should be executed via Coverlet, rather then OpenCover.
How Did You Get This To Happen?
Run a build on a project that is using Coverlet (specifically one that is using .NET Core)
See that the Install-OpenCover task is run, and that it is used to calculate the Test Coverage
Checklist
What You Are Seeing?
When running the
build.bat
on a project that is configured to use Coverlet (via the inclusion of the Coverlet NuGet package) Coverlet is not being used, but instead OpenCover is being used. This should not happen.The problem here is that an invalid check for IsNetCore() is being used, which mean that usage of Coverlet is never allowed. There is a known issue with the IsNetCore() method, where is doesn't correctly detect anything above .NET 5.0, and shouldn't be used.
What is Expected?
When a project is configured to use Coverlet via the NuGet package, unit test coverage should be executed via Coverlet, rather then OpenCover.
How Did You Get This To Happen?
System Details
Installed Packages
Output Log
Additional Context
N/A