Skip to content

Commit bb250f9

Browse files
committed
Remove missing react-router exports in tests
1 parent 71e2a00 commit bb250f9

File tree

7 files changed

+4
-14
lines changed

7 files changed

+4
-14
lines changed

integration/blocking-test.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ test("handles synchronous proceeding correctly", async ({ page }) => {
4040
`,
4141
"app/routes/b.tsx": js`
4242
import * as React from "react";
43-
import { Form, useAction, useBlocker } from "react-router";
43+
import { Form, useBlocker } from "react-router";
4444
export default function Component() {
4545
return (
4646
<div>

integration/client-data-test.ts

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -335,7 +335,6 @@ test.describe("Client Data", () => {
335335
}),
336336
"app/routes/parent.child.tsx": js`
337337
import * as React from 'react';
338-
import { json } from "react-router"
339338
import { Await, useLoaderData } from "react-router"
340339
export function loader() {
341340
return {
@@ -685,7 +684,6 @@ test.describe("Client Data", () => {
685684
}),
686685
"app/routes/parent.child.tsx": js`
687686
import * as React from 'react';
688-
import { json } from "react-router";
689687
import { useLoaderData, useRevalidator } from "react-router";
690688
let isFirstCall = true;
691689
export async function loader({ serverLoader }) {
@@ -763,7 +761,7 @@ test.describe("Client Data", () => {
763761
childClientLoaderHydrate: false,
764762
}),
765763
"app/routes/parent.child.tsx": js`
766-
import { ClientLoaderFunctionArgs, useRouteError } from "react-router";
764+
import { useRouteError } from "react-router";
767765
768766
export function loader() {
769767
throw new Error("Broken!")
@@ -1286,7 +1284,6 @@ test.describe("Client Data", () => {
12861284
}),
12871285
"app/routes/parent.child.tsx": js`
12881286
import * as React from 'react';
1289-
import { json } from "react-router";
12901287
import { Form, useRouteError } from "react-router";
12911288
export async function clientAction({ serverAction }) {
12921289
return await serverAction();
@@ -1508,7 +1505,6 @@ test.describe("Client Data", () => {
15081505
}),
15091506
"app/routes/parent.child.tsx": js`
15101507
import * as React from 'react';
1511-
import { json } from "react-router";
15121508
import { Form, useRouteError } from "react-router";
15131509
export async function clientAction({ serverAction }) {
15141510
return await serverAction();

integration/error-boundary-test.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -971,7 +971,6 @@ test("Allows back-button out of an error boundary after a hard reload", async ({
971971
`,
972972

973973
"app/routes/boom.tsx": js`
974-
import { json } from "react-router";
975974
export function loader() { return boom(); }
976975
export default function() { return <b>my page</b>; }
977976
`,

integration/fetch-globals-test.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@ test.beforeAll(async () => {
1414
fixture = await createFixture({
1515
files: {
1616
"app/routes/_index.tsx": js`
17-
import { json } from "react-router";
1817
import { useLoaderData } from "react-router";
1918
export async function loader() {
2019
const resp = await fetch('https://reqres.in/api/users?page=2');

integration/fetcher-test.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,6 @@ test.describe("useFetcher", () => {
2323
fixture = await createFixture({
2424
files: {
2525
"app/routes/resource-route-action-only.ts": js`
26-
import { json } from "react-router";
2726
export function action() {
2827
return new Response("${CHEESESTEAK}");
2928
}

integration/resource-routes-test.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,6 @@ test.describe("loader in an app", async () => {
114114
}
115115
`,
116116
"app/routes/$.tsx": js`
117-
import { json } from "react-router";
118117
import { useRouteError } from "react-router";
119118
export function loader({ request }) {
120119
throw Response.json({

integration/transition-test.ts

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -139,8 +139,7 @@ test.describe("rendering", () => {
139139
`,
140140

141141
"app/routes/gh-1691.tsx": js`
142-
import { json, redirect } from "react-router";
143-
import { useFetcher} from "react-router";
142+
import { redirect, useFetcher } from "react-router";
144143
145144
export const action = async ( ) => {
146145
return redirect("/gh-1691");
@@ -195,8 +194,7 @@ test.describe("rendering", () => {
195194
`,
196195

197196
"app/routes/parent.child.tsx": js`
198-
import { redirect } from "react-router";
199-
import { useFetcher} from "react-router";
197+
import { redirect, useFetcher } from "react-router";
200198
201199
export const action = async ({ request }) => {
202200
return redirect("/parent");

0 commit comments

Comments
 (0)