diff --git a/packages/react-router-dom/__tests__/data-browser-router-test.tsx b/packages/react-router-dom/__tests__/data-browser-router-test.tsx index dcc44a483f..afcf344633 100644 --- a/packages/react-router-dom/__tests__/data-browser-router-test.tsx +++ b/packages/react-router-dom/__tests__/data-browser-router-test.tsx @@ -29,7 +29,6 @@ import { useFetchers, useLoaderData, useLocation, - useMatches, useNavigate, useNavigation, useRouteError, @@ -5821,7 +5820,12 @@ function testDomRouter( Component() { let fetcher = useFetcher({ key: "me" }); let data = useLoaderData() as { count: number }; - return
{fetcher.data}
+ > + ); }, async loader() { await new Promise((r) => setTimeout(r, 10)); @@ -5853,6 +5857,7 @@ function testDomRouter( dfd.resolve("FETCH"); await waitFor(() => screen.getByText("Num fetchers: 0")); expect(getHtml(container)).toMatch("Page (2)"); + expect(getHtml(container)).toMatch("FETCH"); }); it("submitting fetchers w/redirects are cleaned up on completion", async () => { diff --git a/packages/router/__tests__/flush-sync-test.ts b/packages/router/__tests__/flush-sync-test.ts index deff895602..67b7bdead7 100644 --- a/packages/router/__tests__/flush-sync-test.ts +++ b/packages/router/__tests__/flush-sync-test.ts @@ -1,6 +1,5 @@ -import { IDLE_NAVIGATION } from "../router"; import { cleanup, setup } from "./utils/data-router-setup"; -import { createFormData, tick } from "./utils/utils"; +import { createFormData } from "./utils/utils"; describe("flushSync", () => { // Detect any failures inside the router navigate code