dotnet-test

Generates, audits, and analyzes test coverage for .NET MSTest projects.

Updated Aug 24, 2026
One-click install
npx skills add https://github.com/aggutierrez98/TP-TD --skill dotnet-test-aggutierrez98
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: dotnet-test
Source: https://github.com/aggutierrez98/TP-TD/tree/main/.agents/skills/dotnet-test
Command: npx skills add https://github.com/aggutierrez98/TP-TD --skill dotnet-test-aggutierrez98

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Maintaining a healthy .NET test suite requires detecting anti-patterns, finding untested code, and measuring coverage, which is tedious to do manually across large codebases. ## Core Features & Use Cases - Test Generation & Scaffolding: Write MSTest tests following strict TDD conventions and scaffold new test projects with correct configuration. - Quality Auditing: Detect anti-patterns, assertion weaknesses, and formal test smells such as Eager Test or Mystery Guest. - Coverage & Gap Analysis: Run pseudo-mutation analysis, CRAP score calculation, and untested-source detection to prioritize what to test next. - Use Case: Before closing a feature in a .NET solution, audit the suite for weak assertions, identify classes with no coverage, then generate the missing MSTest tests following the red-green cycle. ## Quick Start Audit the tests in tests/SERVICIOS.Tests for anti-patterns and list production classes that currently have no test coverage.

Frequently Asked Questions about dotnet-test

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I generate MSTest unit tests for .NET code?▼

Use the writing-mstest-tests sub-skill to create tests following MSTest conventions, including correct AreEqual argument order, Assert.Throws instead of ExpectedException, and DynamicData patterns. Tests should follow the strict TDD red-green cycle defined by the strict-tdd skill.

How to find untested code in a .NET project?▼

Use find-untested-sources to list production files and classes without test coverage, or test-gap-analysis for pseudo-mutation analysis that finds behaviors no test covers. Combine with coverage-analysis and crap-score to prioritize what to test first.

What is a CRAP score and how is it used in .NET testing?▼

CRAP score combines cyclomatic complexity with lack of coverage to rank risky code. The crap-score sub-skill calculates it so you can prioritize testing complex, uncovered methods before simpler ones.

Can I refactor static dependencies to make .NET code testable?▼

The generate-testability-wrappers and migrate-static-to-wrapper sub-skills create injectable wrappers for static dependencies. However, in architectures without dependency injection this requires explicit user approval due to its architectural impact.

Why do my .NET tests pass but never actually verify behavior?▼

Tests that never fail are a common anti-pattern detected by the test-anti-patterns sub-skill, along with asserts without messages, order dependencies, and shared state. The assertion-quality sub-skill also flags generic Assert.IsTrue calls that should use specific assertions.