Click here to Skip to main content
15,882,017 members
Articles / Web Development / ASP.NET

JetBrains' dotCover 2.0 Released

12 Jul 2012CPOL3 min read 23.5K   3  
dotCover is a unit test runner and code coverage tool that enables .NET developers to easily see how successful they are in covering their applications with unit tests.

This article is in the Product Showcase section for our sponsors at CodeProject. These articles are intended to provide you with information on products and services that we consider useful and of value to developers.

JetBrains' dotCover 2.0 Released: Check out .NET code coverage tool with integrated test runner!

dotCover is a unit test runner and code coverage tool that enables .NET developers to easily see how successful they are in covering their applications with unit tests.

JetBrains' dotCover is a .NET code coverage tool with an integrated test runner that enables developers to easily determine how much of their code is covered by tests. Code coverage analysis can be executed right from within Visual Studio 2005, 2008, 2010, and 2012 RC. dotCover seamlessly integrates with JetBrains' ReSharper’s unit test runner to enable analyzing coverage of unit tests. If you don’t have ReSharper installed, you can use dotCover's integrated test runner to run and analyze coverage of unit tests based on MSTest, NUnit, xUnit, or the MSpec framework. Coverage details are presented as a tree view.

Image 1

.NET Code Coverage Analysis

dotCover calculates and reports statement-level code coverage for applications built with .NET Framework 1.0 to 4.0, as well as in Silverlight 4 and 5. dotCover helps you learn to what extent your code is covered with unit tests. It also helps developers and QA engineers test software products as thoroughly as possible by reporting code coverage for automated and manual test runs.

Visual Studio Integration

dotCover is a plug-in to Visual Studio giving you the advantage of analyzing and visualizing code coverage without leaving your code editor. Currently dotCover integrates into Visual Studio 2005, 2008, 2010, and 2012 Release Candidate.

Image 2

Coverage Highlighting in Visual Studio

In addition to the tree view for visualizing coverage data, dotCover can highlight covered and uncovered lines of code right in the Visual Studio code editor. You can specify light, medium, or dark color schemes for code highlighting to match your preferred Visual Studio theme.

Image 3

Running and Managing Unit Tests

dotCover comes bundled with a unit test runner that it shares with ReSharper, JetBrains' .NET developer productivity tool, to enable analyzing coverage of unit tests based on MSTest, NUnit, xUnit, or MSpec. However, even if you don’t have ReSharper installed, you can still use dotCover for running and analyzing coverage of unit tests based on NUnit and MSTest. In case you have both ReSharper and dotCover installed, you can choose which unit test runner you want to use, or alternatively use them both.

Image 4

Filtering and Excluding Nodes

From within the coverage tree view, you can exclude a specific node or all nodes except the current node from the coverage calculation. As soon as you've excluded a node or nodes, dotCover instantly recalculates percentages of covered and uncovered code. This is useful for focusing on production code or filtering out code that you're not interested in testing right now.

Image 5

In addition to including or excluding nodes in the coverage tree, you can set global or solution-specific coverage filters based on project, namespace, type, or type member names. Attribute filters are also available that restrict gathering coverage information from code marked with certain attributes. dotCover uses these filters to include or exclude coverage data during a coverage run.

Continuous Coverage Analysis

dotCover includes a command line runner, which is a great fit with continuous integration servers and can easily be called from build scripts. JetBrains' own continuous integration product, TeamCity, bundles dotCover's coverage analysis engine, which helps schedule coverage runs as part of the continuous integration process and generating server-side coverage reports. Via the TeamCity add-in for Visual Studio, dotCover is able to obtain coverage data from a TeamCity server — without running coverage analysis on a local machine.

Image 6

Useful Links

License

This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


Written By
Czech Republic Czech Republic
This member has not yet provided a Biography. Assume it's interesting and varied, and probably something to do with programming.
This is a Organisation (No members)


Comments and Discussions

 
-- There are no messages in this forum --