Skip to content

WIP: Add DependsOnFixture example to dependent tests guide - #1261

Draft
OsirisTerje wants to merge 4 commits into
masterfrom
dependsonfixture-example
Draft

OsirisTerje wants to merge 4 commits into
masterfrom
dependsonfixture-example

Conversation

@OsirisTerje

@OsirisTerje OsirisTerje commented Oct 18, 2026 •

Copy link
Copy Markdown
Member

Adds a three-fixture dependency chain snippet and explains ordering, skipping, AllowFailure and the same-namespace requirement.

Snippets currently prevented from compiling due to nunit/nunit#5478 and nunit/nunit#5479

Adds a three-fixture dependency chain snippet and explains ordering,
skipping, AllowFailure and the same-namespace requirement.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Copilot AI balanced review requested due to automatic review settings October 18, 2026 19:11

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🟢 Approval recommended

The focused documentation changes have no identified blocking issues.

No open issues 🎉

What changed in this PR

Adds a practical fixture-dependency example to NUnit’s dependent tests guide.

Changes:

  • Adds a three-fixture snippet covering seeding, reporting, and cleanup.
  • Explains dependency ordering, skipping, AllowFailure, and fixture restrictions.
File Description
docs/​snippets/​Snippets.NUnit/​DependentFixtureExamples.cs Demonstrates a three-fixture dependency chain.
docs/​articles/​nunit/​writing-tests/​dependent-tests.md Includes the snippet and explains dependency behavior.

Review effort: Balanced

@OsirisTerje OsirisTerje changed the title Add DependsOnFixture example to dependent tests guide WIP: Add DependsOnFixture example to dependent tests guide Oct 18, 2026
The alpha contains the DependsOnFixture fixes from nunit/nunit#5483, so
the DependentFixtures snippet now runs all four tests in order.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
<ItemGroup>
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="18.11.0" />
<PackageReference Include="NUnit" Version="5.0.0" />
<PackageReference Include="NUnit" Version="5.1.0-alpha.0.21" />

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

⚠️ I don't know that we want the docs to reference alpha versions of the software. We should likely hold any docs until 5.1.0 is released

(this may be your intention; just noting because it occurred to me)

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Yes, this is still WIP.
This should have worked in 5.0.0, so I think we need to push out a hotfix for that, so it would end up with 5.0.1.
We have advertised DependsOn* for 5.0, and it doesn't work there, so a hotfix could be the answer. The docs has to be corrected too when we have the final version number where it works.

@stevenaw @manfred-brands What do you think ?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

PS. Is it possible to see how the pages would look, or is that feature not working ?

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

PS. Is it possible to see how the pages would look, or is that feature not working ?

Netlify preview was removed because it rarely worked as intended. See #1045

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

PR preview links are back again 🎉 Just merged master into this branch, which hopefully should generate one

OsirisTerje and others added 2 commits October 21, 2026 22:04
A test can only depend on a test in the same fixture; a single test in
another fixture can not be targeted. A fixture dependency is always the
whole fixture, and it must be in the same namespace. Added to the guide
and to both reference pages.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@github-actions

Copy link
Copy Markdown

📖 Docs preview:

Built from fc9af5a. This link always shows the latest build for this PR; the build for this exact commit is at https://b332bd68.nunit-docs.pages.dev.

Previews are hosted on Cloudflare Pages, are not indexed by search engines, and are removed when the PR is closed. They omit the archived NUnit 2.x documentation (the /2.x/ pages), which never changes; use the live site for those.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants