test(e2e): Add cache origin link tests for cached components in pages - #24739
Merged
Merged
Conversation
Contributor
size-limit report 📦
|
chargome
approved these changes
Sep 25, 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.
Add tests for
cache_originspan links onuse cacheinside rendered pages: cached components and nested cached functions. The key claim beyond the route-handler case: links are per cache entry, so one render with several cached sections carries one link per section, each pointing at its own fill. Currently all in a "failed" state (test.fail()) as this is not yet implemented.Both routes place the cached code in a dynamic hole (awaited
searchParams). Entries served from the prerendered shell (Resume Data Cache) never reach the cache handlers and produce no spans — that path stays untestable until Next.js exposes RDC reads.1. Sibling components: one link per section
The two links must target two different fill spans — origin per section, not per page.
2. Nested caches with different lifetimes (production only)
The inner read happens inside the outer entry's isolated fill context and must still link back to T1.
Closes #24731
Linear: https://linear.app/getsentry/issue/JS-3804/cache-origin-link-tests-for-cached-components-in-pages