Repository navigation
[test] Assert client-rendered content for a rejected lazy element - #37213
Merged
eps1lon merged 1 commit intoSep 10, 2026
Merged
Conversation
|
Comparing: a58f939...6730c64 Critical size changesIncludes critical production bundles, as well as any change greater than 2%:
Significant size changesIncludes any change greater than 0.2%: (No significant changes) Generated by sizebot against 6730c64 |
The test for a lazy element that rejects left its client-render assertion commented out, so it only checked the logged errors. The sibling test for a rejected lazy component asserts the rendered output directly. This enables the assertion so the test covers the client render too.
eps1lon
force-pushed
the
test-assert-lazy-element-client-render
branch
from
September 10, 2026 12:00
d2782d1 to
6730c64
Compare
This was referenced Sep 10, 2026
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.
Summary
should client render a boundary if a lazy element rejectsleft its client-render assertion commented out, so the test only checkedloggedErrors. The sibling testshould client render a boundary if a lazy component rejectshas the same comment 100 lines above with the assertion live.This enables the assertion so the test covers the client render too.
How did you test this change?
yarn test ReactDOMFizzServer(216 tests passed)yarn test ReactDOMFizzServer --prod(216 tests passed)<div>WRONG</div>, which failsyarn prettieryarn linc