Skip to content

Commit 281d82f

Browse files
committed
Write useSuspenseQuery and useMutation tests
1 parent 7ce75e0 commit 281d82f

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

packages/openapi-react-query/test/index.test.tsx

+3-3
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@ import { server, baseUrl, useMockRequestHandler } from "./fixtures/mock-server.j
33
import type { paths } from "./fixtures/api.js";
44
import createClient from "../src/index.js";
55
import createFetchClient from "openapi-fetch";
6-
import { act, render, renderHook, screen, waitFor } from "@testing-library/react";
7-
import { QueryClient, QueryClientProvider, QueryErrorResetBoundary } from "@tanstack/react-query";
6+
import { render, renderHook, screen, waitFor } from "@testing-library/react";
7+
import { QueryClient, QueryClientProvider } from "@tanstack/react-query";
88
import React, { Suspense, type ReactNode } from "react";
99
import { ErrorBoundary } from "react-error-boundary";
1010

@@ -160,7 +160,7 @@ describe("client", () => {
160160
it("should properly propagate error to suspense with a failed http request", async () => {
161161
const fetchClient = createFetchClient<paths>({ baseUrl });
162162
const client = createClient(fetchClient);
163-
const errorSpy = vi.spyOn(console, "error").mockImplementation(() => { }); // to avoid sending errors to console
163+
const errorSpy = vi.spyOn(console, "error").mockImplementation(() => {}); // to avoid sending errors to console
164164

165165
useMockRequestHandler({
166166
baseUrl,

0 commit comments

Comments
 (0)