From 250c1a3bf0cc47e98be02a334147c718496b8231 Mon Sep 17 00:00:00 2001 From: shamoon <4887959+shamoon@users.noreply.github.com> Date: Wed, 4 Feb 2026 21:49:04 -0800 Subject: [PATCH] Mock next/router in signin tests --- src/__tests__/pages/auth/signin.test.jsx | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/__tests__/pages/auth/signin.test.jsx b/src/__tests__/pages/auth/signin.test.jsx index 8f734a3f6..9b40b147f 100644 --- a/src/__tests__/pages/auth/signin.test.jsx +++ b/src/__tests__/pages/auth/signin.test.jsx @@ -11,6 +11,12 @@ vi.mock("utils/config/config", () => ({ getSettings: getSettingsMock, })); +vi.mock("next/router", () => ({ + useRouter: () => ({ + query: {}, + }), +})); + import { getProviders } from "next-auth/react"; import SignInPage, { getServerSideProps } from "pages/auth/signin";