This project was made as reference on how to integrate code coverage tool to use along with Unit test for a CSharp project. The project has been setup for xUnit with Coverlet
I have prepared a reference C# Test Project setup with Code Coverage. The Project is .NET5.0 (unfortunately needs to be) but your project can still have .NET Framework. No issue on that. The project is setup for xUnit and Coverlet. I have prepared a shell script along with it which will handle the code coverage and report generation.
Please go through ProjectSetup.txt: I have explained both scenarios in it i.e New/Existing Project.
Further reading is in ReadmeFirst.md