Repository navigation
Snapshot operation parameter sections, not the whole page - #4687
Merged
Merged
Conversation
`OperationHeadingLevelTests` compared the whole 896-line operation page. It now keeps the heading outline check and snapshots the path parameters, query parameters and request body sections separately (416 lines in total), so an unrelated change to the page no longer breaks it. `AGENTS.md` now describes how to write and accept HTML snapshots. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
akira28
disabled auto-merge
November 4, 2026 16:35
The request body section holds an applicability popover whose data payload changes with shared product text, so the snapshot ignores it as the whole-page one did. Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>
akira28
enabled auto-merge (squash)
November 4, 2026 16:37
Contributor
Docs preview (local build)Handbook preview: https://docs-v3-preview.elastic.dev/elastic/docs-builder/pull/4687/ Sample changed pages: |
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.
OperationHeadingLevelTestsnow snapshots the path parameters, query parameters and request body sections separately instead of the whole operation page, andAGENTS.mddocuments how to write HTML snapshots.Affects: Internals only
Prompt summary: Follow up on the first snapshot pilot, which still compared a very large page, by snapshotting smaller components instead. Document the snapshot workflow so contributors can repeat it.
Why
The pilot snapshot in
OperationHeadingLevelTestscovers 896 lines of one page. An unrelated change, such as the popover text in #4311, already broke it once. A reviewer also cannot tell which part of the page a diff concerns.What
One snapshot per section
The heading outline test keeps its check of one
h1, thenh2sections and a nestedh3. Three new tests snapshot#path-params-list,#query-params-listand#request-body-list, 416 lines in total. The authentication and responses blocks already have their own partial snapshots in #4684 and #4686.Snapshot guidance
AGENTS.md(the target ofCLAUDE.md) now explains when to use a snapshot, how to narrow it, how to accept new files withSNAPSHOT_ACCEPT=1, and to run a mutation check before committing.Verify
Renaming the
property-listclass in_PropertyList.cshtmlfails all three new tests.🤖 Generated with Claude Code