xunit-v3-discovery

Fix xUnit v3 test projects that compile but show zero discovered tests under dotnet test.

6 stars

Best use case

xunit-v3-discovery is best used when you need a repeatable AI agent workflow instead of a one-off prompt.

Fix xUnit v3 test projects that compile but show zero discovered tests under dotnet test.

Teams using xunit-v3-discovery should expect a more consistent output, faster repeated execution, less prompt rewriting.

When to use this skill

  • You want a reusable workflow that can be run more than once with consistent structure.

When not to use this skill

  • You only need a quick one-off answer and do not need a reusable workflow.
  • You cannot install or maintain the underlying files, dependencies, or repository context.

Installation

Claude Code / Cursor / Codex

$curl -o ~/.claude/skills/xunit-v3-discovery/SKILL.md --create-dirs "https://raw.githubusercontent.com/cwoodruff/morespeakers-com/main/.squad/skills/xunit-v3-discovery/SKILL.md"

Manual Installation

  1. Download SKILL.md from GitHub
  2. Place it in .claude/skills/xunit-v3-discovery/SKILL.md inside your project
  3. Restart your AI agent — it will auto-discover the skill

How xunit-v3-discovery Compares

Feature / Agentxunit-v3-discoveryStandard Approach
Platform SupportNot specifiedLimited / Varies
Context Awareness High Baseline
Installation ComplexityUnknownN/A

Frequently Asked Questions

What does this skill do?

Fix xUnit v3 test projects that compile but show zero discovered tests under dotnet test.

Where can I find the source code?

You can find the source code on GitHub using the link provided at the top of the page.

SKILL.md Source

## Context
Use this when a .NET test project builds cleanly, but `dotnet test` reports that no tests are available.

## Pattern
- Check whether the project uses xUnit v3 packages without a Visual Studio/VSTest runner package.
- If `dotnet test` is the expected execution path, add `xunit.runner.visualstudio` to the test project.
- Re-run the targeted test project immediately to confirm tests are actually discovered and executed.

## Example
- `src\MoreSpeakers.Data.Tests\MoreSpeakers.Data.Tests.csproj` needed `xunit.runner.visualstudio` before `ExpertiseDataStoreResultTests` would run.

## Anti-Patterns
- Do not assume green build output means tests ran.
- Do not add new test projects when the existing one only needs runner configuration.