From 987355a66dccf06ea0fc2a5a778cd9ee59e58fdb Mon Sep 17 00:00:00 2001 From: "ildar.timerbaev" Date: Mon, 20 May 2024 22:08:12 +0600 Subject: [PATCH] Fixed tests --- .../comment/__snapshots__/index.spec.tsx.snap | 4 ++-- src/common/components/comment/index.spec.tsx | 13 +++++++++++-- 2 files changed, 13 insertions(+), 4 deletions(-) diff --git a/src/common/components/comment/__snapshots__/index.spec.tsx.snap b/src/common/components/comment/__snapshots__/index.spec.tsx.snap index ac8eae3d2b8..1c946b46810 100644 --- a/src/common/components/comment/__snapshots__/index.spec.tsx.snap +++ b/src/common/components/comment/__snapshots__/index.spec.tsx.snap @@ -220,7 +220,7 @@ exports[`(1) Default render 1`] = `
@@ -586,7 +586,7 @@ exports[`(2) Cancellable, in progress 1`] = `
diff --git a/src/common/components/comment/index.spec.tsx b/src/common/components/comment/index.spec.tsx index e4661696bf3..c08933d9a81 100644 --- a/src/common/components/comment/index.spec.tsx +++ b/src/common/components/comment/index.spec.tsx @@ -6,6 +6,7 @@ import { entryInstance1, globalInstance, UiInstance } from "../../helper/test-he import emojiData from "../../../../public/emoji.json"; import { withStore } from "../../tests/with-store"; +import { QueryClient, QueryClientProvider } from "@tanstack/react-query"; jest.mock("../../api/misc", () => ({ getEmojiData: () => @@ -40,13 +41,21 @@ const defProps = { it("(1) Default render", () => { const props = { ...defProps }; - const component = withStore(); + const component = withStore( + + + + ); expect(component.toJSON()).toMatchSnapshot(); }); it("(2) Cancellable, in progress", () => { const props = { ...{ inProgress: true, cancellable: true, defText: "foo" }, ...defProps }; - const component = withStore(); + const component = withStore( + + + + ); expect(component.toJSON()).toMatchSnapshot(); });