Repository navigation
test(e2e): pin streaming-error loading state on the raw stream, not the transient DOM - #696
Merged
Merged
Conversation
…he transient DOM The direct-load streaming-error test asserted the loading fallback was visible in the live DOM before the error boundary replaced it. That window is hydration-speed-dependent, and #694's head-executing module scripts shrink it by design: page.goto resolves at load (the error already streamed), and on a warm runner hydration swaps in the error boundary before the first locator poll — failed 4/4 on a fast local preview, flaked on CI shard rangojs-router-e2e (production, 1, 2), while slower runners pass. The contract worth pinning is deterministic on the stream: the shell ships the fallback markup, React's errored-boundary marker (<!--$!-->) arrives later in the same body, and the browser lands on the error boundary. The SPA-navigation sibling keeps its DOM assertion — its window is the full 500ms handler delay on the client transition, not a hydration race. Red-before-green: old form 4/4 red locally, new form 4/4 green production + green dev; full error-boundary file 18/18.
commit: |
ivogt
added a commit
that referenced
this pull request
Jul 5, 2026
…ts capture starves sibling captures on GH runners With the composition test already CI-dev-skipped, the warmup's module-warm GET was the last CI trigger of its background capture, whose per-request /__rsc_prerender app-graph re-import grinds the runner long enough to blow SIBLING captures' 5s quiet windows — the rotating eternal-MISS victim seen across four CI runs (warmup on one shard, the composition probe, then /ppr-shell?probe=stream once the rest were quiet; #695/#696 green before the route existed; local runs unaffected). Locally the route stays warmed and every test runs. Lift with the dev-endpoint capture hardening follow-up.
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.
The direct-load streaming-error test raced hydration: it asserted the loading fallback was visible in the live DOM before the error boundary replaced it, but that window is hydration-speed-dependent and #694's head-executing module scripts shrink it by design.
page.gotoresolves atload— for this route the 500ms error has already streamed by then — so on a warm runner hydration swaps in the error boundary before the first locator poll. Observed: failed 4/4 on a fast local preview and on the CI shardrangojs-router-e2e (production, 1, 2)of the #694 head run; passed on slower runners and on main's post-merge run.The contract worth pinning is deterministic on the raw stream and unaffected by hydration timing:
data-testid="streaming-error-loading").<!--$!-->) streams after it in the same body.The SPA-navigation sibling test keeps its DOM assertion — its loading window is the full 500ms handler delay on a client transition, not a hydration race.
Semantics: no product behavior change; test-only.
Test plan:
error-boundary.test.ts: 18/18 across both projects.check:e2e-bucketing, lint, format clean.