Skip to content

[Sprint 7] docs(adr): record xUnit v3 migration decision + performance analysis#169

Merged
mpaulosky merged 2 commits into
sprint/7-xunit-v3-pilotfrom
squad/166-xunit-v3-adr
Apr 25, 2026
Merged

[Sprint 7] docs(adr): record xUnit v3 migration decision + performance analysis#169
mpaulosky merged 2 commits into
sprint/7-xunit-v3-pilotfrom
squad/166-xunit-v3-adr

Conversation

@mpaulosky

Copy link
Copy Markdown
Owner

Closes #166

Summary

This ADR documents the xUnit v3 migration decision and pilot strategy for Domain.Tests in Sprint 7.

Contents

  • Context: Why xUnit v3? Ecosystem alignment, performance, MTP adoption
  • Decision: Adopt v3 incrementally starting with Domain.Tests pilot (Sprint 7)
  • Rationale: Incremental rollout validates process before broad deployment
  • Consequences: API changes, migration effort, performance gains, tooling improvements
  • Performance Analysis:
    • Baseline: 104 ms (42 tests, Domain.Tests)
    • Projected: 88–99 ms (5–15% improvement)
    • CI impact: 42–55 seconds (estimated 5–10% savings when fully migrated)
  • Rollout Plan: Sprints 7–13, per-project versioning strategy via Directory.Packages.props

Validation

  • ✅ Release build passes
  • ✅ ADR follows existing format (markdown + YAML front matter)
  • ✅ Includes performance data, alternatives, mitigation strategies
  • ✅ References xUnit v3 migration guide and related issues

Related

…166)

- Document pilot scope: Domain.Tests in Sprint 7
- Include v3 rationale: MTP adoption, performance gains, ecosystem alignment
- Provide rollout plan: Sprints 7–13, per-project versioning strategy
- Add performance analysis: baseline metrics (104ms Domain.Tests), projected 5–15% improvement
- Include migration examples: before/after test code, API changes
- Outline risk mitigation: incremental rollout, measurement plan, fallback strategy

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot AI review requested due to automatic review settings April 25, 2026 01:50
@github-actions github-actions Bot added the squad Squad triage inbox — Lead will assign to a member label Apr 25, 2026
@github-actions

Copy link
Copy Markdown
Contributor

🏗️ PR Added to Squad Triage Queue

This PR has been labeled with squad and added to the triage queue.

Next steps:

  • The squad Lead will review and assign to an appropriate team member
  • A squad:member label will be added after triage

If you know which squad member should handle this, you can add the appropriate squad:member label yourself.

- Appended Sprint 7 work summary to .squad/agents/pippin/history.md
- Documented ADR structure, validation, learnings, and team coordination
- Recorded performance metrics (104ms baseline, 5–15% projected improvement)
- Outlined rollout plan (Sprints 7–13) and next steps for Gimli

Note: Decision record created in .squad/decisions/inbox/pippin-xunit-v3-adr.md
for Scribe to merge into decisions.md per squad workflow.

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds a new Architecture Decision Record (ADR) documenting the Sprint 7 decision to pilot an incremental migration from xUnit v2 to xUnit v3 (starting with tests/Domain.Tests), including rationale, consequences, performance analysis, and a rollout plan.

Changes:

  • Introduces a new ADR describing the xUnit v3 pilot decision and incremental rollout strategy.
  • Documents estimated performance impact and a measurement plan for validating improvements.
  • Provides migration notes and an appendix example to illustrate expected source-level changes.

Comment on lines +1 to +4
---
post_title: "ADR: Migrate to xUnit v3 (Pilot)"
author1: "Pippin"
post_slug: "adr-sprint7-xunit-v3-migration"

Copilot AI Apr 25, 2026

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

PR/issue #166 acceptance criteria call for a new ADR in docs/decisions/ and for it to be linked from docs/decisions/index.md, but this PR adds the ADR under docs/adr/ and does not update the decisions index (currently only ADR-001 is listed). Either move/rename this to the decisions folder + add an index entry, or update the PR/issue description to match the intended docs/adr/ location.

Copilot uses AI. Check for mistakes.
Comment on lines +53 to +57
<ItemGroup>
<PackageVersion Include="xunit" Version="2.9.3" />
<PackageVersion Include="xunit.v3" Version="3.0.x" />
<PackageVersion Include="xunit.runner.visualstudio" Version="3.1.5" />
</ItemGroup>

Copilot AI Apr 25, 2026

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The ADR example shows <PackageVersion Include="xunit.v3" Version="3.0.x" />, but Directory.Packages.props requires an explicit NuGet version (no x wildcard). This example is likely to be copy/pasted and will fail restore/build; consider using a concrete version (or clearly mark it as a placeholder with a non-copyable token).

Copilot uses AI. Check for mistakes.
## Rationale

**Why a pilot?**
- xUnit v3 is a major version with new APIs (e.g., `[Fact]` becomes `[Test]`, `TheoryData<T>` changes). Broad, fast migration risks introducing bugs.

Copilot AI Apr 25, 2026

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This states [Fact] becomes [Test], which reads like a required rename. The repo’s xUnit v3 guidance indicates [Fact] remains supported for backward compatibility (see .github/prompts/xunit.prompt.md:231). Suggest rephrasing to "prefer [Test]" (or "[Test] is the v3 default") to avoid implying migrations must rewrite every [Fact].

Suggested change
- xUnit v3 is a major version with new APIs (e.g., `[Fact]` becomes `[Test]`, `TheoryData<T>` changes). Broad, fast migration risks introducing bugs.
- xUnit v3 is a major version with new APIs (e.g., `[Test]` is the v3 default and is preferred over `[Fact]`, `TheoryData<T>` changes). Broad, fast migration risks introducing bugs.

Copilot uses AI. Check for mistakes.
@github-actions

Copy link
Copy Markdown
Contributor

Test Results Summary

209 tests  ±0   209 ✅ ±0   14s ⏱️ ±0s
  5 suites ±0     0 💤 ±0 
  5 files   ±0     0 ❌ ±0 

Results for commit 8dfecc7. ± Comparison against base commit e7035b1.

@codecov

codecov Bot commented Apr 25, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 72.12%. Comparing base (e7035b1) to head (8dfecc7).
⚠️ Report is 1 commits behind head on sprint/7-xunit-v3-pilot.

Additional details and impacted files
@@                   Coverage Diff                    @@
##           sprint/7-xunit-v3-pilot     #169   +/-   ##
========================================================
  Coverage                    72.12%   72.12%           
========================================================
  Files                           43       43           
  Lines                          721      721           
  Branches                       112      112           
========================================================
  Hits                           520      520           
  Misses                         150      150           
  Partials                        51       51           
🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@mpaulosky
mpaulosky merged commit 330d1c5 into sprint/7-xunit-v3-pilot Apr 25, 2026
13 of 14 checks passed
@mpaulosky
mpaulosky deleted the squad/166-xunit-v3-adr branch April 25, 2026 02:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

squad Squad triage inbox — Lead will assign to a member

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants