[Spector] Add 200 body / 204 no-content success response scenario - #11677
Open
JoshLove-msft with Copilot wants to merge 2 commits into
Open
[Spector] Add 200 body / 204 no-content success response scenario#11677JoshLove-msft with Copilot wants to merge 2 commits into
JoshLove-msft with Copilot wants to merge 2 commits into
Conversation
|
Azure Pipelines: Successfully started running 1 pipeline(s). 1 pipeline(s) were filtered out due to trigger conditions. There may be pipelines that require an authorized user to comment /azp run to run. |
Co-authored-by: JoshLove-msft <54595583+JoshLove-msft@users.noreply.github.com>
Copilot
AI
changed the title
[WIP] Add HTTP Spector scenario for 200 and 204 responses
[Spector] Add 200 body / 204 no-content success response scenario
Aug 14, 2026
JoshLove-msft
marked this pull request as ready for review
August 14, 2026 22:38
JoshLove-msft
requested review from
catalinaperalta,
iscai-msft,
Mark Cowlishaw (markcowl),
Timothee Guerin (timotheeguerin) and
Jeff Fisher (xirzec)
as code owners
August 14, 2026 22:38
|
You can try these changes here
|
commit: |
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.
Adds HTTP Spector coverage for an operation with multiple success responses where one variant carries a body and the other does not. This lets emitters verify they distinguish a
204empty-success variant from a nullable body on a single response.Scenario
New namespace
Response.BodyOrNoContentunderresponse/body-or-no-content. Both operations return the same union so the generated shape matches the issue exactly; a mock endpoint is deterministic, so each declared outcome gets its own route:Changes
specs/response/body-or-no-content/main.tsp— scenario definitions with docs calling out the validation goals (both classified successful,200deserialized normally,204skips body deserialization, raw status/headers available).specs/response/body-or-no-content/mockapi.ts—passOnSuccessmocks for the200-with-body and204-no-content routes.spec-summary.md— regenerated..chronus/changes/—featureentry for@typespec/http-specs.