Skip to content

fix(router): flaky router preload cache test#266

Merged
mohamedmansour merged 1 commit intomainfrom
fix/test/e2e
Apr 22, 2026
Merged

fix(router): flaky router preload cache test#266
mohamedmansour merged 1 commit intomainfrom
fix/test/e2e

Conversation

@mohamedmansour
Copy link
Copy Markdown
Contributor

The "preload cache is consumed" test stored a non-preload entry with default staleTime: 0, causing lookupCache to immediately consider it stale. Additionally, non-preload entries get complete: false from storeCacheEntry, so lookupCache returned null.

Fix: pass preload: true (matches the test intent) and explicitly set complete = true after storage so lookupCache finds a ready entry.

The "preload cache is consumed" test stored a non-preload entry with
default `staleTime: 0`, causing `lookupCache` to immediately consider
it stale. Additionally, non-preload entries get `complete: false` from
`storeCacheEntry`, so `lookupCache` returned null.

Fix: pass `preload: true` (matches the test intent) and explicitly set
`complete = true` after storage so `lookupCache` finds a ready entry.

Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
@mohamedmansour mohamedmansour changed the title Fix flaky router preload cache test fix(router): flaky router preload cache test Apr 22, 2026
@mohamedmansour mohamedmansour requested a review from a team April 22, 2026 20:36
@mohamedmansour mohamedmansour merged commit ae9790f into main Apr 22, 2026
21 checks passed
@mohamedmansour mohamedmansour deleted the fix/test/e2e branch April 22, 2026 21:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants