There is this great tool in Visual Studio 2012 to show the test coverage of the source code. On the official MSDN homepage it is shown under menu Test -> Analyze Code Coverage
.
But in my Test
menu this entry is missing and I could'nt figure out why. Can someone please explain? Am I missing an addon/plugin?
Update: Visual Studio 2012 Professional with Update 3.
Starting in Visual Studio 2022 Update 2, you can enable faster code coverage test results by selecting Tools > Options > Environment > Preview Features, then selecting Code coverage experience improvements, and then restarting Visual Studio.
Code coverage feature in Visual Studio 2017 enabled only in Version 15.3. 3 or more. Next load your project, click on the Test Menu, Select Analyze Code Coverage menu and select All Tests, which will run all the tests and display code coverage results.
Code coverage will highlight lines of code that are not covered by tests. It will list the uncovered lines under the problems window. And it conveniently shows the coverage ratio in the status bar.
According to the MSDN page you linked:
Requirements
Visual Studio Ultimate, Visual Studio Premium
So it will not be available on Professional.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With