summaryrefslogtreecommitdiffhomepage
path: root/frontend/src/tests/index.tsx
diff options
context:
space:
mode:
Diffstat (limited to 'frontend/src/tests/index.tsx')
-rw-r--r--frontend/src/tests/index.tsx12
1 files changed, 10 insertions, 2 deletions
diff --git a/frontend/src/tests/index.tsx b/frontend/src/tests/index.tsx
index 8239af064..9053be909 100644
--- a/frontend/src/tests/index.tsx
+++ b/frontend/src/tests/index.tsx
@@ -1,11 +1,19 @@
import { AllProviders } from "@/providers";
import { render, RenderOptions } from "@testing-library/react";
-import { ReactElement } from "react";
+import { FunctionComponent, ReactElement, StrictMode } from "react";
+
+const AllProvidersWithStrictMode: FunctionComponent = ({ children }) => {
+ return (
+ <StrictMode>
+ <AllProviders>{children}</AllProviders>
+ </StrictMode>
+ );
+};
const customRender = (
ui: ReactElement,
options?: Omit<RenderOptions, "wrapper">
-) => render(ui, { wrapper: AllProviders, ...options });
+) => render(ui, { wrapper: AllProvidersWithStrictMode, ...options });
// re-export everything
export * from "@testing-library/react";