Configuring Test Reports and Code Coverage
This section contains articles concerning support of test reports, code inspections, and code coverage in TeamCity.
Test Reports in TeamCity
TeamCity provides out-of-the-box support for a number of testing frameworks. To reduce the feedback time on test failures, it reports detailed test results on the fly whenever possible. These results are displayed in the build overview. See the list of currently supported testing frameworks.
Code Inspection in TeamCity
TeamCity comes with code analysis tools capable of inspecting your source code on the fly, finding and reporting common problems and anti-patterns.
The following inspections tools are bundled with TeamCity:
Inspection results are reported in the Code Inspection tab of the Build Results page.
Qodana: runs static analysis checks, tracks how the code quality changes over time, detects incompatible dependency licenses, and much more. See the following Qodana help article for the detailed setup instructions: Integration with TeamCity.
TeamCity can also be integrated with external reporting tools.
Code Coverage in TeamCity
Code coverage is a number of metrics that measure how your code is covered by unit tests. TeamCity supports the following coverage engines out of the box:
Java, see Configuring Java Code Coverage
.NET: see Configuring .NET Code Coverage
To get the code coverage information displayed in TeamCity for the supported tools, you need to configure it in the dedicated section of a build runner's settings page. The following build runners include code coverage support:
The chart for code coverage is also available on the Statistic Charts tab of a build configuration.