-
Notifications
You must be signed in to change notification settings - Fork 1
V10.0.2/minor fixes #39
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
…ls when a fixture was not in a valid state invoking ConfigureHost
Caution Review failedThe pull request is closed. WalkthroughThis update introduces version 10.0.2 across multiple Codebelt.Extensions.Xunit packages, updating dependencies to the latest compatible versions and refining internal validation logic. Bug fixes address fixture state checks in host configuration methods, and workflow automation is updated to use version 2 of reusable pipelines. Minor improvements enhance logging robustness and test environment configuration. Changes
Sequence Diagram(s)sequenceDiagram
participant TestRunner
participant ManagedHostFixture
participant Host
TestRunner->>ManagedHostFixture: ConfigureHost(hostTest)
ManagedHostFixture->>ManagedHostFixture: HasValidState()
alt Invalid State
ManagedHostFixture-->>TestRunner: Return (early exit)
else Valid State
ManagedHostFixture->>Host: Build and configure host
end
sequenceDiagram
participant Logger
participant ITestOutputHelper
Logger->>ITestOutputHelper: WriteLine(message)
alt InvalidOperationException thrown
Logger-->>Logger: Catch and ignore exception
end
Possibly related PRs
Poem
📜 Recent review detailsConfiguration used: CodeRabbit UI 📒 Files selected for processing (1)
✨ Finishing Touches
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. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This pull request implements minor fixes across workflows, release notes, changelog entries, and source code to improve compatibility, address state validation issues in hosting fixtures, and refine logging behavior. Key changes include:
- Upgrading workflow dependencies to v2 in pipelines.
- Updating package release notes and the changelog to version 10.0.2.
- Adding state validation checks to ManagedHostFixture and ManagedWebHostFixture and enhancing logging in XunitTestLogger.
Reviewed Changes
Copilot reviewed 13 out of 13 changed files in this pull request and generated 2 comments.
Show a summary per file
File | Description |
---|---|
testenvironments.json | Updated Docker image tag to reflect the new test runner environment |
src/Codebelt.Extensions.Xunit.Hosting/XunitTestLogger.cs | Wrapped write operations in a try/catch to gracefully handle missing active test output |
src/Codebelt.Extensions.Xunit.Hosting/ManagedHostFixture.cs | Added early exit based on fixture state validation |
src/Codebelt.Extensions.Xunit.Hosting/GenericHostFixtureExtensions.cs | Removed redundant check from HasValidState |
src/Codebelt.Extensions.Xunit.Hosting.AspNetCore/WebHostFixtureExtensions.cs | Simplified the valid state validation by excluding the Application property check |
src/Codebelt.Extensions.Xunit.Hosting.AspNetCore/ManagedWebHostFixture.cs | Added state validation check and updated callback invocation |
Directory.Packages.props | Upgraded Microsoft.NET.Test.Sdk version |
CHANGELOG.md, PackageReleaseNotes.txt (multiple files) | Updated version and details for 10.0.2 release |
.github/workflows/pipelines.yml | Updated workflow references from v1 to v2 |
{ | ||
if (hostTest == null) { throw new ArgumentNullException(nameof(hostTest)); } | ||
if (!HasTypes(hostTest.GetType(), typeof(HostTest<>))) { throw new ArgumentOutOfRangeException(nameof(hostTest), typeof(HostTest<>), $"{nameof(hostTest)} is not assignable from HostTest<T>."); } | ||
if (!this.HasValidState()) { return; } // had to include this due to dual-call this method (one uncontrolled from xUnit library reflection magic; second controlled from this library) |
Copilot
AI
Jun 1, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Consider adding a logging statement or warning message before returning when HasValidState() is false so that unexpected early exits during host configuration can be more easily diagnosed.
if (!this.HasValidState()) { return; } // had to include this due to dual-call this method (one uncontrolled from xUnit library reflection magic; second controlled from this library) | |
if (!this.HasValidState()) | |
{ | |
Logger?.LogWarning("Exiting ConfigureHost early because the host is in an invalid state."); | |
return; | |
} // had to include this due to dual-call this method (one uncontrolled from xUnit library reflection magic; second controlled from this library) |
Copilot uses AI. Check for mistakes.
{ | ||
ArgumentNullException.ThrowIfNull(hostTest); | ||
if (!HasTypes(hostTest.GetType(), typeof(WebHostTest<>))) { throw new ArgumentOutOfRangeException(nameof(hostTest), typeof(WebHostTest<>), $"{nameof(hostTest)} is not assignable from WebHostTest<T>."); } | ||
if (!this.HasValidState()) { return; } // had to include this due to dual-call this method (one uncontrolled from xUnit library reflection magic; second controlled from this library) |
Copilot
AI
Jun 1, 2025
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Consider adding a logging or warning message for the early return when HasValidState() returns false, to help developers trace potential configuration issues in the web host fixture.
if (!this.HasValidState()) { return; } // had to include this due to dual-call this method (one uncontrolled from xUnit library reflection magic; second controlled from this library) | |
if (!this.HasValidState()) | |
{ | |
Logger?.LogWarning("Exiting ConfigureHost early because HasValidState() returned false. This may indicate a configuration issue."); | |
return; | |
} // had to include this due to dual-call this method (one uncontrolled from xUnit library reflection magic; second controlled from this library) |
Copilot uses AI. Check for mistakes.
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #39 +/- ##
==========================================
- Coverage 92.26% 91.99% -0.28%
==========================================
Files 48 48
Lines 931 937 +6
Branches 120 122 +2
==========================================
+ Hits 859 862 +3
- Misses 62 65 +3
Partials 10 10 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actionable comments posted: 2
♻️ Duplicate comments (2)
src/Codebelt.Extensions.Xunit.Hosting/ManagedHostFixture.cs (1)
40-40
: Consider adding logging for better debugging experience.The guard clause implementation looks correct for preventing dual calls. However, as previously suggested, adding a logging statement would help with debugging unexpected early exits during host configuration.
Consider applying this enhancement:
- if (!this.HasValidState()) { return; } // had to include this due to dual-call this method (one uncontrolled from xUnit library reflection magic; second controlled from this library) + if (!this.HasValidState()) + { + Logger?.LogWarning("Exiting ConfigureHost early because the host is in an invalid state."); + return; + } // had to include this due to dual-call this method (one uncontrolled from xUnit library reflection magic; second controlled from this library)src/Codebelt.Extensions.Xunit.Hosting.AspNetCore/ManagedWebHostFixture.cs (1)
43-43
: Consider adding logging for better debugging experience.The guard clause implementation is consistent with the similar fix in
ManagedHostFixture.cs
. However, as previously suggested, adding a logging statement would help developers trace potential configuration issues.Consider applying this enhancement:
- if (!this.HasValidState()) { return; } // had to include this due to dual-call this method (one uncontrolled from xUnit library reflection magic; second controlled from this library) + if (!this.HasValidState()) + { + Logger?.LogWarning("Exiting ConfigureHost early because HasValidState() returned false. This may indicate a configuration issue."); + return; + } // had to include this due to dual-call this method (one uncontrolled from xUnit library reflection magic; second controlled from this library)
🧹 Nitpick comments (4)
src/Codebelt.Extensions.Xunit.Hosting/XunitTestLogger.cs (1)
44-51
: Good defensive programming, but consider improving observability and test coverage.The try-catch block appropriately handles the scenario where
ITestOutputHelper.WriteLine()
throwsInvalidOperationException
when no test is active. However, consider these improvements:
- Test Coverage: The static analysis indicates this code path isn't covered by tests.
- Observability: Silently swallowing exceptions might make debugging difficult.
Consider adding a debug log or counter to track when this scenario occurs:
catch (InvalidOperationException) { // can happen when there is no currently active test (e.g., you should use the ITestOutputHelperAccessor capability) + System.Diagnostics.Debug.WriteLine($"No active test context available for logging: {message}"); }
Also consider adding a unit test to verify this exception handling works correctly.
🧰 Tools
🪛 GitHub Check: codecov/patch
[warning] 48-49: src/Codebelt.Extensions.Xunit.Hosting/XunitTestLogger.cs#L48-L49
Added lines #L48 - L49 were not covered by tests
[warning] 51-51: src/Codebelt.Extensions.Xunit.Hosting/XunitTestLogger.cs#L51
Added line #L51 was not covered by testsCHANGELOG.md (1)
17-17
: Fix formatting issues flagged by static analysis.Static analysis tools have identified minor formatting issues that should be addressed for professional documentation:
- Line 17: Use proper markdown link format for the URL instead of bare URL
- Line 23: Missing article "the" before "ConfigureHost method"
Apply these formatting fixes:
- AddXunitTestLogging method on the ServiceCollectionExtensions class in the Codebelt.Extensions.Xunit.Hosting namespace to be forgiving when no active test is present (relates to https://github.com/xunit/xunit/issues/2377) + AddXunitTestLogging method on the ServiceCollectionExtensions class in the Codebelt.Extensions.Xunit.Hosting namespace to be forgiving when no active test is present (relates to [xunit/xunit#2377](https://github.com/xunit/xunit/issues/2377))- ManagedWebHostFixture class in the Codebelt.Extensions.Xunit.Hosting.AspNetCore namespace to exit ConfigureHost method if the fixture is not in a valid state (e.g., configuration delegate properties are null) + ManagedWebHostFixture class in the Codebelt.Extensions.Xunit.Hosting.AspNetCore namespace to exit the ConfigureHost method if the fixture is not in a valid state (e.g., configuration delegate properties are null)🧰 Tools
🪛 markdownlint-cli2 (0.17.2)
17-17: Bare URL used
null(MD034, no-bare-urls)
.nuget/Codebelt.Extensions.Xunit.Hosting.AspNetCore/PackageReleaseNotes.txt (2)
8-8
: Refine grammar for the ConfigureHost exit note
Add the missing article and use “an invalid state” for consistency.
Apply this diff:- FIXED ManagedWebHostFixture class in the Codebelt.Extensions.Xunit.Hosting.AspNetCore namespace to exit ConfigureHost method if the fixture is not in a valid state (e.g., configuration delegate properties are null) + FIXED ManagedWebHostFixture class in the Codebelt.Extensions.Xunit.Hosting.AspNetCore namespace to exit the ConfigureHost method if the fixture is in an invalid state (e.g., configuration delegate properties are null)🧰 Tools
🪛 LanguageTool
[uncategorized] ~8-~8: You might be missing the article “the” here.
Context: ...it.Hosting.AspNetCore namespace to exit ConfigureHost method if the fixture is not in a valid...(AI_EN_LECTOR_MISSING_DETERMINER_THE)
11-11
: Improve grammar for HasValidState method change
Include the definite articles for clarity.
Apply this diff:- CHANGED HasValidState method on the WebHostFixtureExtensions class in the Codebelt.Extensions.Xunit.Hosting.AspNetCore namespace to exclude check of Application property + CHANGED HasValidState method on the WebHostFixtureExtensions class in the Codebelt.Extensions.Xunit.Hosting.AspNetCore namespace to exclude the check of the Application property
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (13)
.github/workflows/pipelines.yml
(4 hunks).nuget/Codebelt.Extensions.Xunit.App/PackageReleaseNotes.txt
(1 hunks).nuget/Codebelt.Extensions.Xunit.Hosting.AspNetCore/PackageReleaseNotes.txt
(1 hunks).nuget/Codebelt.Extensions.Xunit.Hosting/PackageReleaseNotes.txt
(1 hunks).nuget/Codebelt.Extensions.Xunit/PackageReleaseNotes.txt
(1 hunks)CHANGELOG.md
(1 hunks)Directory.Packages.props
(1 hunks)src/Codebelt.Extensions.Xunit.Hosting.AspNetCore/ManagedWebHostFixture.cs
(2 hunks)src/Codebelt.Extensions.Xunit.Hosting.AspNetCore/WebHostFixtureExtensions.cs
(1 hunks)src/Codebelt.Extensions.Xunit.Hosting/GenericHostFixtureExtensions.cs
(1 hunks)src/Codebelt.Extensions.Xunit.Hosting/ManagedHostFixture.cs
(1 hunks)src/Codebelt.Extensions.Xunit.Hosting/XunitTestLogger.cs
(1 hunks)testenvironments.json
(1 hunks)
🧰 Additional context used
🧠 Learnings (5)
📓 Common learnings
Learnt from: gimlichael
PR: codebeltnet/xunit#17
File: src/Codebelt.Extensions.Xunit.Hosting/Codebelt.Extensions.Xunit.Hosting.csproj:22-26
Timestamp: 2024-10-09T14:10:40.721Z
Learning: In the `src/Codebelt.Extensions.Xunit.Hosting/Codebelt.Extensions.Xunit.Hosting.csproj` file, only certain .NET 8 packages are available in version 8.0.1, while others remain at 8.0.0, so package versions may differ due to availability.
.nuget/Codebelt.Extensions.Xunit/PackageReleaseNotes.txt (1)
Learnt from: gimlichael
PR: codebeltnet/xunit#17
File: src/Codebelt.Extensions.Xunit.Hosting/Codebelt.Extensions.Xunit.Hosting.csproj:22-26
Timestamp: 2024-10-09T14:10:40.721Z
Learning: In the `src/Codebelt.Extensions.Xunit.Hosting/Codebelt.Extensions.Xunit.Hosting.csproj` file, only certain .NET 8 packages are available in version 8.0.1, while others remain at 8.0.0, so package versions may differ due to availability.
.nuget/Codebelt.Extensions.Xunit.App/PackageReleaseNotes.txt (1)
Learnt from: gimlichael
PR: codebeltnet/xunit#17
File: src/Codebelt.Extensions.Xunit.Hosting/Codebelt.Extensions.Xunit.Hosting.csproj:22-26
Timestamp: 2024-10-09T14:10:40.721Z
Learning: In the `src/Codebelt.Extensions.Xunit.Hosting/Codebelt.Extensions.Xunit.Hosting.csproj` file, only certain .NET 8 packages are available in version 8.0.1, while others remain at 8.0.0, so package versions may differ due to availability.
.nuget/Codebelt.Extensions.Xunit.Hosting/PackageReleaseNotes.txt (1)
Learnt from: gimlichael
PR: codebeltnet/xunit#17
File: src/Codebelt.Extensions.Xunit.Hosting/Codebelt.Extensions.Xunit.Hosting.csproj:22-26
Timestamp: 2024-10-09T14:10:40.721Z
Learning: In the `src/Codebelt.Extensions.Xunit.Hosting/Codebelt.Extensions.Xunit.Hosting.csproj` file, only certain .NET 8 packages are available in version 8.0.1, while others remain at 8.0.0, so package versions may differ due to availability.
.nuget/Codebelt.Extensions.Xunit.Hosting.AspNetCore/PackageReleaseNotes.txt (1)
Learnt from: gimlichael
PR: codebeltnet/xunit#17
File: src/Codebelt.Extensions.Xunit.Hosting/Codebelt.Extensions.Xunit.Hosting.csproj:22-26
Timestamp: 2024-10-09T14:10:40.721Z
Learning: In the `src/Codebelt.Extensions.Xunit.Hosting/Codebelt.Extensions.Xunit.Hosting.csproj` file, only certain .NET 8 packages are available in version 8.0.1, while others remain at 8.0.0, so package versions may differ due to availability.
🧬 Code Graph Analysis (3)
src/Codebelt.Extensions.Xunit.Hosting.AspNetCore/WebHostFixtureExtensions.cs (1)
src/Codebelt.Extensions.Xunit.Hosting/GenericHostFixtureExtensions.cs (1)
HasValidState
(17-21)
src/Codebelt.Extensions.Xunit.Hosting.AspNetCore/ManagedWebHostFixture.cs (1)
src/Codebelt.Extensions.Xunit.Hosting.AspNetCore/WebMinimalHostFixtureExtensions.cs (1)
HasValidState
(18-22)
src/Codebelt.Extensions.Xunit.Hosting/ManagedHostFixture.cs (1)
src/Codebelt.Extensions.Xunit.Hosting.AspNetCore/WebMinimalHostFixtureExtensions.cs (1)
HasValidState
(18-22)
🪛 LanguageTool
CHANGELOG.md
[uncategorized] ~23-~23: You might be missing the article “the” here.
Context: ...it.Hosting.AspNetCore namespace to exit ConfigureHost method if the fixture is not in a valid...
(AI_EN_LECTOR_MISSING_DETERMINER_THE)
.nuget/Codebelt.Extensions.Xunit.Hosting.AspNetCore/PackageReleaseNotes.txt
[uncategorized] ~8-~8: You might be missing the article “the” here.
Context: ...it.Hosting.AspNetCore namespace to exit ConfigureHost method if the fixture is not in a valid...
(AI_EN_LECTOR_MISSING_DETERMINER_THE)
🪛 markdownlint-cli2 (0.17.2)
CHANGELOG.md
17-17: Bare URL used
null
(MD034, no-bare-urls)
🪛 GitHub Check: codecov/patch
src/Codebelt.Extensions.Xunit.Hosting/XunitTestLogger.cs
[warning] 48-49: src/Codebelt.Extensions.Xunit.Hosting/XunitTestLogger.cs#L48-L49
Added lines #L48 - L49 were not covered by tests
[warning] 51-51: src/Codebelt.Extensions.Xunit.Hosting/XunitTestLogger.cs#L51
Added line #L51 was not covered by tests
⏰ Context from checks skipped due to timeout of 90000ms (2)
- GitHub Check: call-codeql / 🛡️ Security Analysis
- GitHub Check: call-sonarcloud / 🔬 Code Quality Analysis
🔇 Additional comments (13)
.github/workflows/pipelines.yml (1)
30-30
: LGTM: Consistent workflow dependency upgrades.The upgrade from
@v1
to@v2
for all reusable workflows is well-executed and consistent across build, pack, test, and deploy jobs. This should provide access to improved features and compatibility.Also applies to: 44-44, 57-57, 92-92
testenvironments.json (1)
12-12
:✅ Verification successful
Verify the updated Docker image exists and maintains compatibility.
The removal of the "mono-" prefix from the Docker image tag suggests a change from Mono runtime to native .NET runtime. Please ensure the new image
gimlichael/ubuntu-testrunner:net8.0.409-9.0.300
exists and maintains compatibility with your test suite.
🏁 Script executed:
#!/bin/bash # Description: Verify the Docker image exists and can be pulled successfully # Expected: Image should be available and pullable echo "Checking if Docker image exists and is accessible..." docker pull gimlichael/ubuntu-testrunner:net8.0.409-9.0.300 echo "Comparing with previous image (if available)..." docker pull gimlichael/ubuntu-testrunner:mono-net8.0.409-9.0.300 2>/dev/null || echo "Previous mono image not available locally"Length of output: 538
🏁 Script executed:
#!/bin/bash # Verify existence of Docker tags via Docker Registry HTTP API echo "Retrieving Docker Hub token..." TOKEN=$(curl -fs 'https://auth.docker.io/token?service=registry.docker.io&scope=repository:gimlichael/ubuntu-testrunner:pull' \ | grep -o '"token":"[^"]*"' \ | sed 's/"token":"\([^"]*\)"/\1/') if [ -z "$TOKEN" ]; then echo "❌ Failed to retrieve auth token." exit 1 fi # Check new image tag echo "Checking tag net8.0.409-9.0.300..." STATUS_NET=$(curl -fs -o /dev/null -w '%{http_code}' \ -H "Authorization: Bearer $TOKEN" \ -H "Accept: application/vnd.docker.distribution.manifest.v2+json" \ https://registry-1.docker.io/v2/gimlichael/ubuntu-testrunner/manifests/net8.0.409-9.0.300) echo "→ net8.0.409-9.0.300 HTTP status: $STATUS_NET" # Check previous mono image tag echo "Checking tag mono-net8.0.409-9.0.300..." STATUS_MONO=$(curl -fs -o /dev/null -w '%{http_code}' \ -H "Authorization: Bearer $TOKEN" \ -H "Accept: application/vnd.docker.distribution.manifest.v2+json" \ https://registry-1.docker.io/v2/gimlichael/ubuntu-testrunner/manifests/mono-net8.0.409-9.0.300) echo "→ mono-net8.0.409-9.0.300 HTTP status: $STATUS_MONO" # Interpret results if [ "$STATUS_NET" -eq 200 ]; then echo "✅ New image exists." else echo "❌ New image not found or inaccessible." fi if [ "$STATUS_MONO" -eq 200 ]; then echo "ℹ️ Previous mono image still exists." else echo "ℹ️ Previous mono image not found." fiLength of output: 12004
Docker image tags verified – both
net8.0.409-9.0.300
andmono-net8.0.409-9.0.300
exist on Docker Hub (HTTP 200).
No further changes totestenvironments.json
are needed; proceed with thenet8.0.409-9.0.300
image and ensure your test suite is green against the native .NET runtime variant.Directory.Packages.props (1)
11-11
:✅ Verification successful
LGTM: Standard test SDK upgrade.
The upgrade to
Microsoft.NET.Test.Sdk
version 17.14.0 is a minor version increment that should maintain compatibility while providing bug fixes and improvements.
🌐 Web query:
What are the changes and improvements in Microsoft.NET.Test.Sdk version 17.14.0 compared to 17.13.0?
💡 Result:
The release notes for Microsoft.NET.Test.Sdk version 17.14.0-preview-25107-01 indicate several key changes and improvements compared to version 17.13.0:
.NET Version Updates: This release upgrades support to .NET 8 and .NET 9. Projects targeting .NET 6.0 or other end-of-life frameworks should either update to .NET 8 or newer or pin their Microsoft.NET.Test.Sdk version to 17.13.0. (newreleases.io)
UWP .NET 9 Support: Introduces a process query flag to support UWP applications targeting .NET 9. (newreleases.io)
WinUI and UWP .NET 9 Fixes: Addresses build issues for WinUI and UWP projects targeting .NET 9. (newreleases.io)
Test Discovery Improvements: Fixes an issue where communication errors were reported during test discovery aborts. (newreleases.io)
VSIX Enhancements: Adds a dump minitool to the VSIX package for improved diagnostics. (newreleases.io)
These updates aim to enhance compatibility with newer .NET versions, improve support for UWP and WinUI projects, and provide better diagnostic tools for test execution.
Citations:
- 1: https://newreleases.io/project/github/microsoft/vstest/release/v17.14.0-preview-25107-01?utm_source=openai
- 2: https://newreleases.io/project/github/microsoft/vstest/release/v17.14.0-preview-25107-01?utm_source=openai
- 3: https://newreleases.io/project/github/microsoft/vstest/release/v17.14.0-preview-25107-01?utm_source=openai
- 4: https://newreleases.io/project/github/microsoft/vstest/release/v17.14.0-preview-25107-01?utm_source=openai
- 5: https://newreleases.io/project/github/microsoft/vstest/release/v17.14.0-preview-25107-01?utm_source=openai
🏁 Script executed:
#!/bin/bash echo "Listing target frameworks across all .csproj files:" rg --glob '*.csproj' '<TargetFramework' -nLength of output: 616
Approve upgrade: Microsoft.NET.Test.Sdk 17.14.0 aligns with project frameworks
Projects in this repo target net8.0 and net9.0 (see .csproj files), and the 17.14.0 release adds first-class support and fixes for .NET 8/.NET 9, UWP and WinUI projects, plus diagnostics improvements. No compatibility issues expected.
– No changes required.
.nuget/Codebelt.Extensions.Xunit/PackageReleaseNotes.txt (1)
1-6
: LGTM! Version update follows established format.The new version 10.0.2 entry is properly formatted and accurately documents the dependency upgrades as intended for this release.
.nuget/Codebelt.Extensions.Xunit.App/PackageReleaseNotes.txt (1)
1-7
: LGTM! Consistent version update across packages.The new version 10.0.2 entry maintains consistency with the main package and properly documents the dependency upgrades for this coordinated release.
src/Codebelt.Extensions.Xunit.Hosting/GenericHostFixtureExtensions.cs (2)
15-15
: LGTM! Documentation updated to reflect simplified validation logic.The XML documentation correctly reflects the removal of the Host property check from the validation criteria, maintaining accuracy between documentation and implementation.
19-21
: LGTM! Simplified validation logic aligns with PR objectives.The implementation correctly validates only the essential callback properties, supporting the early exit guards in ConfigureHost methods to prevent invalid state configurations.
src/Codebelt.Extensions.Xunit.Hosting.AspNetCore/WebHostFixtureExtensions.cs (1)
19-21
: LGTM! Implementation correctly simplified to focus on essential validation.The validation logic properly delegates to the base
HasValidState
method and adds the web-specificConfigureApplicationCallback
check, aligning with the overall simplification strategy.src/Codebelt.Extensions.Xunit.Hosting.AspNetCore/ManagedWebHostFixture.cs (1)
77-77
: Explicit delegate invocation is consistent.The explicit
Invoke
call on theConfigureApplicationCallback
delegate is good practice and ensures clarity about the delegate execution..nuget/Codebelt.Extensions.Xunit.Hosting/PackageReleaseNotes.txt (1)
1-13
: Release notes accurately document the changes.The version 10.0.2 release notes correctly document the bug fixes and improvements implemented in the source code files. The descriptions of the
ManagedHostFixture
early exit fix and theHasValidState
method changes align with the actual code modifications.CHANGELOG.md (1)
10-24
: Changelog entry accurately documents version 10.0.2 changes.The changelog entry properly follows the Keep a Changelog format and accurately documents the bug fixes and improvements. The content is consistent with the release notes and reflects the actual code changes made.
🧰 Tools
🪛 LanguageTool
[uncategorized] ~23-~23: You might be missing the article “the” here.
Context: ...it.Hosting.AspNetCore namespace to exit ConfigureHost method if the fixture is not in a valid...(AI_EN_LECTOR_MISSING_DETERMINER_THE)
🪛 markdownlint-cli2 (0.17.2)
17-17: Bare URL used
null(MD034, no-bare-urls)
.nuget/Codebelt.Extensions.Xunit.Hosting.AspNetCore/PackageReleaseNotes.txt (2)
1-2
: Release notes version updated correctly
The version bump to 10.0.2 and supported TFMs (.NET 9 and .NET 8) aligns with the PR objectives.
5-5
: Dependency upgrade note is clear
The description of upgraded dependencies for all supported TFMs accurately reflects the changes.
src/Codebelt.Extensions.Xunit.Hosting.AspNetCore/WebHostFixtureExtensions.cs
Outdated
Show resolved
Hide resolved
- CHANGED Dependencies have been upgraded to the latest compatible versions for all supported target frameworks (TFMs) | ||
|
||
# Bug Fixes | ||
- FIXED ManagedWebHostFixture class in the Codebelt.Extensions.Xunit.Hosting.AspNetCore namespace to exit ConfigureHost method if the fixture is not in a valid state (e.g., configuration delegate properties are null) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Missing release note for ConfigureApplicationCallback invocation change
The PR summary and changelog mention switching to explicit Invoke
syntax for ConfigureApplicationCallback
, but this isn’t documented here. Please add an entry under Improvements to cover that change.
🧰 Tools
🪛 LanguageTool
[uncategorized] ~8-~8: You might be missing the article “the” here.
Context: ...it.Hosting.AspNetCore namespace to exit ConfigureHost method if the fixture is not in a valid...
(AI_EN_LECTOR_MISSING_DETERMINER_THE)
🤖 Prompt for AI Agents
In .nuget/Codebelt.Extensions.Xunit.Hosting.AspNetCore/PackageReleaseNotes.txt
at line 8, add a new entry under the Improvements section to document the change
to using explicit Invoke syntax for ConfigureApplicationCallback. This entry
should clearly state that the ConfigureApplicationCallback invocation was
updated to use explicit Invoke calls, reflecting the PR summary and changelog
accurately.
This pull request includes updates to workflows, package release notes, changelog entries, and source code to improve compatibility, fix bugs, and enhance functionality. The most notable changes include upgrading workflow dependencies, introducing fixes for state validation in hosting fixtures, and improving the developer experience for logging and testing.
Workflow Updates:
.github/workflows/pipelines.yml
: Updated all workflow dependencies (dotnet-build
,dotnet-pack
,dotnet-test
,nuget-push
) to versionv2
for improved compatibility and features. [1] [2] [3] [4]Package Release Notes and Changelog:
.nuget/*/PackageReleaseNotes.txt
: Updated to version10.0.2
with notes on upgraded dependencies, bug fixes, and improvements for all supported target frameworks. [1] [2] [3] [4]CHANGELOG.md
: Added a new entry for version10.0.2
, summarizing changes and fixes, including updates toHasValidState
andAddXunitTestLogging
methods, and fixes forManagedHostFixture
andManagedWebHostFixture
classes.Hosting Fixtures and Logging Improvements:
ManagedWebHostFixture.cs
andManagedHostFixture.cs
: Added state validation checks toConfigureHost
methods to prevent errors caused by uncontrolled dual calls. [1] [2]WebHostFixtureExtensions.cs
andGenericHostFixtureExtensions.cs
: RefinedHasValidState
methods to simplify validation logic by excluding certain property checks. [1] [2]XunitTestLogger.cs
: Enhanced logging to handle scenarios where no active test is present, avoidingInvalidOperationException
.Miscellaneous Updates:
Directory.Packages.props
: UpgradedMicrosoft.NET.Test.Sdk
to version17.14.0
.testenvironments.json
: Updated Docker image for Ubuntu test runner to reflect the latest environment.Summary by CodeRabbit
Bug Fixes
New Features
Chores
Documentation