From a5d2aa8f231aa408ab92b1a8b9b9f1244465f2a8 Mon Sep 17 00:00:00 2001 From: Pascal Euhus Date: Mon, 23 Oct 2023 21:16:59 +0200 Subject: [PATCH] fix frontend tests --- .../NavigationDrawer.test.tsx.snap | 76 ------------------- .../webui/src/views/ModuleDetails.test.tsx | 1 + .../webui/src/views/ProviderDetails.test.tsx | 1 + 3 files changed, 2 insertions(+), 76 deletions(-) diff --git a/src/main/webui/src/components/nav/__snapshots__/NavigationDrawer.test.tsx.snap b/src/main/webui/src/components/nav/__snapshots__/NavigationDrawer.test.tsx.snap index 772eb740..12cf780f 100644 --- a/src/main/webui/src/components/nav/__snapshots__/NavigationDrawer.test.tsx.snap +++ b/src/main/webui/src/components/nav/__snapshots__/NavigationDrawer.test.tsx.snap @@ -96,44 +96,6 @@ Object { /> - -
-
- -
-
- - Management - -
- -
-
@@ -231,44 +193,6 @@ Object { /> - -
-
- -
-
- - Management - -
- -
-
diff --git a/src/main/webui/src/views/ModuleDetails.test.tsx b/src/main/webui/src/views/ModuleDetails.test.tsx index f32487f2..bdc2daab 100644 --- a/src/main/webui/src/views/ModuleDetails.test.tsx +++ b/src/main/webui/src/views/ModuleDetails.test.tsx @@ -4,6 +4,7 @@ import ModuleDetails from "./ModuleDetails"; jest.mock("react-router-dom", () => ({ ...jest.requireActual("react-router-dom"), + useNavigate: () => jest.fn(), useLocation: () => ({ pathname: "localhost:3000/module/foo/bar/aws", }), diff --git a/src/main/webui/src/views/ProviderDetails.test.tsx b/src/main/webui/src/views/ProviderDetails.test.tsx index 4563aba0..e036d7bc 100644 --- a/src/main/webui/src/views/ProviderDetails.test.tsx +++ b/src/main/webui/src/views/ProviderDetails.test.tsx @@ -4,6 +4,7 @@ import ProviderDetails from "./ProviderDetails"; jest.mock("react-router-dom", () => ({ ...jest.requireActual("react-router-dom"), + useNavigate: () => jest.fn(), useLocation: () => ({ pathname: "localhost:3000/providers/foo/bar", }),