Skip to content

Covers xUnit v3 testing for .NET: Fact and Theory attributes, fixtures, parallelism, and IAsyncLifetime setup.

CCM score
50 of 100
skills.sh installs
625
GitHub stars
94
last updated
Aug 21, 2026
View on GitHub

Own this skill? Claim it

What it does

  • Covers [Fact] and [Theory] with [InlineData], [MemberData], and [ClassData], plus strongly typed TheoryDataRow<T> rows
  • Includes IClassFixture<T> and ICollectionFixture<T> for sharing expensive resources such as database connections across tests
  • Notes v2 compatibility differences, including ValueTask return types for IAsyncLifetime and removed assertion message parameters
  • Designed for .NET 8.0+ projects that use xUnit v3 or are migrating from v2, with test scaffolding handled by a separate skill

Install

$ npx -y skills add wshaddix/dotnet-skills --skill dotnet-xunit -y

Installs into .agents/skills for every agent it finds here, and .claude/skills for Claude Code.

Files

dotnet-xunit

xUnit v3 testing framework features for .NET. Covers [Fact] and [Theory] attributes, test fixtures (IClassFixture, ICollectionFixture), parallel execution configuration, IAsyncLifetime for async setup/teardown, custom assertions, and xUnit analyzers. Includes v2 compatibility notes where behavior differs.

Version assumptions: xUnit v3 primary (.NET 8.0+ baseline). Where v3 behavior differs from v2, compatibility notes are provided inline. xUnit v2 remains widely used; many projects will encounter both versions during migration.

Out of scope: Test project scaffolding (creating xUnit projects, package references, Directory.Build.props) is owned by [skill:dotnet-add-testing]. Testing strategy and test type decisions are covered by [skill:dotnet-testing-strategy]. Integration testing patterns (WebApplicationFactory, Testcontainers) are covered by [skill:dotnet-integration-testing].

Prerequisites: Test project already scaffolded via [skill:dotnet-add-testing] with xUnit packages referenced. Run [skill:dotnet-version-detection] to confirm .NET 8.0+ baseline for xUnit v3 support.

Details

Repository
github.com/wshaddix/dotnet-skills
Categories
Testing & QA, .NET & C#
First seen
Jun 3, 2026

More from wshaddix/dotnet-skills

All 13

Similar to Dotnet Xunit

More Testing & QA