Skip to content

chore(deps): update dependency nunit to v5 - #6903

Merged
thomhurst merged 2 commits into
mainfrom
renovate/major-nunit
Sep 28, 2026
Merged

thomhurst merged 2 commits into
mainfrom
renovate/major-nunit

Conversation

@thomhurst

@thomhurst thomhurst commented Sep 27, 2026 •

Copy link
Copy Markdown
Owner

This PR contains the following updates:

Package Type Update Change
NUnit (source) nuget major 4.6.1 → 5.0.0

Release Notes

nunit/nunit (NUnit)

v5.0.0: Version 5.0.0

See release notes for details.


Configuration

📅 Schedule: (UTC)

  • Branch creation
    • At any time (no schedule defined)
  • Automerge
    • At any time (no schedule defined)

🚦 Automerge: Enabled.

♻ Rebasing: Whenever PR is behind base branch, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about this update again.


  • If you want to rebase/retry this PR, check this box

This PR has been generated by Mend Renovate CLI.

Summary by CodeRabbit

  • New Features
    • Improved NUnit migration support for NUnit 5, including recognition of its assertion types and updated generated migration examples.
  • Documentation
    • Updated the NUnit migration guide’s async exception-testing example to reflect NUnit 3/4 usage.
  • Chores
    • Updated the centrally managed NUnit package to version 5.0.0.

@thomhurst thomhurst added dependencies Pull requests that update a dependency file MAJOR renovate-bot labels Sep 27, 2026
@thomhurst
thomhurst enabled auto-merge (squash) September 27, 2026 15:13
@thomhurst
thomhurst deployed to Pull Requests September 27, 2026 15:13 — with GitHub Actions Active
@thomhurst
thomhurst deployed to Pull Requests September 27, 2026 15:13 — with GitHub Actions Active
@chatgpt-codex-connector

chatgpt-codex-connector Bot commented Sep 27, 2026 •

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review ✅ Completed 2026-09-27T22:42:20.937797Z 1070562 New commits
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@coderabbitai

coderabbitai Bot commented Sep 27, 2026 •

Copy link
Copy Markdown

Review in Change Stack →

Navigate logical layers of code changes, visualize relationships, and explore their blast radius.

No actionable comments were generated in the recent review. 🎉

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Advanced

Run ID: 23f898c1-ef8f-4792-838e-33429938183d

📥 Commits

Reviewing files that changed from the base of the PR and between 1070562 and e97238e.

📒 Files selected for processing (5)
  • docs/docs/migration/nunit.md
  • src/TUnit.Analyzers/Migrators/NUnitMigrationAnalyzer.cs
  • tests/TUnit.Analyzers.Tests/NUnitMigrationAnalyzerTests.cs
  • tests/TUnit.Analyzers.Tests/TUnit.Analyzers.Tests.csproj
  • tools/TUnit.DocSnippetGenerator/Program.cs

Included review availability: This review used your included allowance. Your plan provides up to 8 included reviews per hour; 2 remain after this review.


📝 Walkthrough

Walkthrough

The NUnit package version changes to 5.0.0. Analyzer detection, test assembly references, generated migration snippets, and migration documentation are updated for NUnit 5.

Changes

NUnit 5 migration support

Layer / File(s) Summary
NUnit package and test assembly setup
Directory.Packages.props, tests/TUnit.Analyzers.Tests/TUnit.Analyzers.Tests.csproj, tests/TUnit.Analyzers.Tests/NUnitMigrationAnalyzerTests.cs
The central NUnit package version changes to 5.0.0. The test project copies NUnit framework and legacy assemblies to its output. Analyzer tests use those assembly paths and report a FileNotFoundException with the expected path and build instruction if an assembly is missing.
Analyzer and migration examples
src/TUnit.Analyzers/Migrators/NUnitMigrationAnalyzer.cs, tools/TUnit.DocSnippetGenerator/Program.cs, docs/docs/migration/nunit.md
The analyzer recognizes NUnit.Framework.StringAssert. Generated snippets resolve CollectionAssert and StringAssert from NUnit.Framework. The NUnit 3/4 documentation example omits await from Assert.ThrowsAsync; the TUnit example continues to use await.

Priority: ⬇️ Low

Estimated code review effort: 2 (Simple) | ~10 minutes

Change: Other

Merge Risk: ⚪ Minimal · up to e9723

The NUnit 5 update preserves the repository’s inspected benchmark and analyzer-test workflows, and the generated migration snippets use NUnit 5 namespaces. No concrete user-facing or build/test regression remains, so the change is ready to merge after normal checks.

Architecture Summary

Architecture risk: 🔵 Low · up to 72a1b

The change affects 1 system.

Changed systems: Directory.Packages.props

Architecture concerns
No architecture-level concerns identified.

Review details

Systems and components

  • observed — Directory.Packages.props (service) was modified; 1 changed file maps to changed impact.

Before / after behavior

  • observed — Modified behavior in Directory.Packages.props: The centrally managed NUnit package version changed from 4.6.1 to 5.0.0.
🚥 Pre-merge checks | ✅ 4 | ❌ 1

❌ Failed checks (1 warning)

Check name Status Explanation Resolution
Docstring Coverage ⚠️ Warning Docstring coverage is 20.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 5 functions across 3 files. (2 skipped: 2… Write docstrings for the functions missing them to satisfy the coverage threshold.
✅ Passed checks (4 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The title clearly and concisely identifies the main change: updating the NUnit dependency to version 5.
Linked Issues check ✅ Passed Check skipped because no linked issues were found for this pull request.
Out of Scope Changes check ✅ Passed Check skipped because no linked issues were found for this pull request.
Full details: Docstring Coverage

Explanation

Docstring coverage is 20.00% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 5 functions across 3 files. (2 skipped: 2 unsupported.)

  • Fix all pre-merge checks with AI
✨ Finishing Touches 💡 1
📝 Generate docstrings 💡
  • Commit to this branch
  • Create a new PR
🧪 Generate unit tests (beta)
  • Commit to this branch
  • Create a new PR

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

A rabbit checks the NUnit trail,
With framework names now set to scale.
The snippets hop to namespaces new,
Test assemblies join the queue.
One less await marks the page,
And version five turns the stage.

Comment @coderabbitai help to get the list of available commands.

@greptile-apps

greptile-apps Bot commented Sep 27, 2026 •

Copy link
Copy Markdown
Contributor

RetriggerConfidence Score: 5/5

[Medium risk] Updates test framework dependency and analyzer compatibility.

The PR appears safe to merge; no outstanding actionable findings were identified.

Summary

This PR updates the repository’s NUnit dependency to 5.0.0 and adapts its migration tooling and documentation.

  • Updates generated snippet aliases and analyzer framework detection for NUnit 5 types.
  • Uses NUnit’s net8.0 assemblies in analyzer tests to avoid reference-assembly version conflicts.

Reviews (4) · Last reviewed commit: "Fix build and docs for NUnit 5"

@chatgpt-codex-connector chatgpt-codex-connector Bot 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.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 1070562db2

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread Directory.Packages.props
NUnit 5 still ships ClassicAssert in NUnit.Framework.Legacy (nunit.framework.legacy.dll),
but moved StringAssert, CollectionAssert, FileAssert and DirectoryAssert back to the
NUnit.Framework namespace, and Assert.ThrowsAsync now returns an awaitable Task.

- Doc snippet generator: alias StringAssert/CollectionAssert to NUnit.Framework.
- NUnit migration guide: await ThrowsAsync in the NUnit example (CS4014 under NUnit 5).
- NUnit migration analyzer: also detect NUnit.Framework.StringAssert when probing
  whether NUnit is referenced.
- Analyzer tests: reference NUnit's net8.0 build. NUnit 5's net10.0 build references
  System.Runtime 10.0 and raises CS1705 against the verifier's Net90 reference assemblies.
@thomhurst
thomhurst deployed to Pull Requests September 28, 2026 16:42 — with GitHub Actions Active
@thomhurst
thomhurst deployed to Pull Requests September 28, 2026 16:42 — with GitHub Actions Active
@thomhurst
thomhurst deployed to Pull Requests September 28, 2026 16:42 — with GitHub Actions Active
@thomhurst

Copy link
Copy Markdown
Owner Author

Edited/Blocked Notification

Renovate will not automatically rebase this PR, because it does not recognize the last commit author and assumes somebody else may have edited the PR.

You can manually request rebase by checking the rebase/retry box above.

⚠️ Warning: custom changes will be lost.

@thomhurst
thomhurst merged commit 77e5c8b into main Sep 28, 2026
27 checks passed
@thomhurst
thomhurst deleted the renovate/major-nunit branch September 28, 2026 18:30
This was referenced Sep 29, 2026

This branch was successfully deployed

1 active deployment
Pull Requests — e97238e5 Deployed Sep 28, 2026 by thomhurst via modularpipeline (ubuntu-latest) #19553
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies Pull requests that update a dependency file MAJOR renovate-bot

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants