Skip to content
This repository has been archived by the owner on Sep 10, 2024. It is now read-only.

Make sure the dummy router finished loading in the test environment #2403

Merged
merged 1 commit into from
Feb 27, 2024

Conversation

sandhose
Copy link
Member

@sandhose sandhose commented Feb 27, 2024

I can't figure out why it was the case, maybe a bug in @tanstack/router, but sometimes the router would render an empty <div> instead of its children.
This adds a router.load() call in the router test utility, and exports a routerReady promise which resolves when the router is ready to be used.

The big diff is because we had empty snapshots because of this. 🤦

@sandhose sandhose added the A-Frontend Changes on the React frontend label Feb 27, 2024
Copy link

cloudflare-workers-and-pages bot commented Feb 27, 2024

Deploying with  Cloudflare Pages  Cloudflare Pages

Latest commit: be47076
Status: ✅  Deploy successful!
Preview URL: https://bfab921a.matrix-authentication-service-docs.pages.dev
Branch Preview URL: https://quenting-frontend-dummy-rout.matrix-authentication-service-docs.pages.dev

View logs

@sandhose sandhose requested a review from t3chguy February 27, 2024 09:04
@sandhose sandhose force-pushed the quenting/frontend/dummy-router-load branch from f60932c to be47076 Compare February 27, 2024 10:00
@sandhose sandhose enabled auto-merge February 27, 2024 10:04
@sandhose sandhose disabled auto-merge February 27, 2024 10:24
@sandhose sandhose merged commit 9a6439a into main Feb 27, 2024
16 checks passed
@sandhose sandhose deleted the quenting/frontend/dummy-router-load branch February 28, 2024 16:24
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
A-Frontend Changes on the React frontend
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants