Use the open-source free `coverlet` toolchain for .NET code coverage.
coverlet.collectorcoverlet.msbuild
Write, run, or repair .NET tests that use TUnit. Use when a repo uses `TUnit`, `TUnit.Playwright`, `[Test]`, `[Arguments]`, `ClassDataSource`, `SharedType.PerTestSession`, or Microsoft.Testing.Platform-based execution.
ClassDataSource<...>(Shared = SharedType.PerTestSession), ParallelLimiter, TUnit.Playwright, or --treenode-filtertest command from AGENTS.md. If the repo has no explicit command yet, start with dotnet test PROJECT_OR_SOLUTION.- tests are source-generated at build time - tests run in parallel by default - built-in analyzers should remain enabled
- plain TUnit tests for isolated logic - shared AppHost/Aspire fixtures for HTTP, SignalR, SSE, or UI flows - WebApplicationFactory layered over shared Aspire infra when tests need Host DI services, IGrainFactory, or other runtime internals
ClassDataSource<Fixture>(Shared = SharedType.PerTestSession) instead of booting distributed infrastructure per test.dotnet test ... -- --treenode-filter "...". Keep TUnit arguments after --.[Test], [Arguments], hooks, and dependencies only when they make the scenario clearer, not because the framework allows it.--treenode-filter rather than VSTest-style --filterSharedType.PerTestSession or an equivalent reuse patternreferences/patterns.mdreferences/migration.mdreferences/tunit.mdreferences/integration-testing.mdUse the open-source free `coverlet` toolchain for .NET code coverage.
Write, run, or repair .NET tests that use MSTest.
Write, run, or repair .NET tests that use NUnit.