Add ProblemDetailsService tests for Conflict, NotFound, InternalServerError, and UnprocessableEntity result types#65099
Draft
Copilot wants to merge 2 commits intofeature/typed-results-problemdetails-servicefrom
Draft
Conversation
5 tasks
Co-authored-by: mikekistler <85643503+mikekistler@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Add tests for additional result types in ProblemDetailsService
Add ProblemDetailsService tests for Conflict, NotFound, InternalServerError, and UnprocessableEntity result types
Jan 16, 2026
Contributor
|
@copilot it looks like the CI tests are failing. Please investigate and fix. |
Contributor
Author
I investigated the potential CI failures and ran comprehensive local validation: ✅ All 25 new tests pass consistently (5 tests × 5 result types) The tests validate:
Could you please share the specific CI error message or logs? This will help me identify if it's:
All tests pass locally on both Debug and Release builds. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Add ProblemDetailsService tests for additional result types
Extends ProblemDetailsService test coverage to match BadRequest implementation
Description
Adds comprehensive test coverage for
Conflict<T>,NotFound<T>,InternalServerError<T>, andUnprocessableEntity<T>result types to verify ProblemDetailsService integration. Each type now has tests covering:ProblemDetailsOptions.CustomizeProblemDetailsHttpValidationProblemDetailssupportTest infrastructure fixes:
Microsoft.AspNetCore.Http.Jsonusing directive forAddProblemDetailsextensionCreateServiceCollectionto includeAddOptions()and proper logger registrationBadRequestOfTResultTests.csfrom parent PRAll tests validate that TypedResults with ProblemDetails correctly utilize IProblemDetailsService customizations when available, with graceful fallback otherwise.
💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.