TeamCity Cloud 2023.07 Help

.NET Testing Frameworks Support

To support the real-time reporting of test results, TeamCity should either run tests using its own test runner or be able to interact with the testing frameworks to receive notifications on test events.

The following .NET testing plugins are supported by TeamCity out of the box.

NUnit

To report NUnit test results, use the .NET or NUnit build runner.

Note that the NUnit runner supports only .NET Framework. To run tests for .NET Core projects (and .NET Framework projects version 4.0 or later), use the .NET build runner with the test command instead.

The details of the NUnit support in TeamCity and alternative approaches are described in this article.

MSTest

Refer to the MSTest Support page for details. Note that due to specifics of the MSTest tool, TeamCity does not support on-the-fly test reporting for MSTest.

MSPec

A dedicated test runner is available for MSPec support. Refer to the MSpec page for details.

Gallio

Starting with version 3.0.4, Gallio supports on-the-fly test results reporting to the TeamCity server.

Other testing frameworks (for example, MbUnit, NBehave, NUnit, xUnit.Net, and csUnit) are supported by Gallio and thus can provide test reporting back to TeamCity.

Gallio also supports NCover, which allows including coverage HTML reports to the TeamCity build overview. See this article for details.

xUnit

See the general information about the xUnit support and a related blog post.

Note that we do not recommend using xUnit in combination with other testing frameworks in TeamCity, since it might mix up the test reporting results.

Last modified: 25 January 2022