Skip to content

Commit bdfa337

Browse files
committed
Stabilize navigation mocks in web tests
1 parent da1ef31 commit bdfa337

3 files changed

Lines changed: 3 additions & 0 deletions

File tree

web/tests/app-pricing-page.test.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ const redirect = mock((href: unknown) => {
1515
// carry every export another test in the suite might import.
1616
mock.module("next/navigation", () => ({
1717
redirect,
18+
usePathname: () => "/",
1819
notFound: () => {
1920
throw new Error("notFound");
2021
},

web/tests/app-pro-welcome-page.test.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ const redirect = mock((href: unknown) => {
99
// carry every export another test in the suite might import.
1010
mock.module("next/navigation", () => ({
1111
redirect,
12+
usePathname: () => "/",
1213
notFound: () => {
1314
throw new Error("notFound");
1415
},

web/tests/billing-success-page.test.tsx

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ const retrieveSession = mock(async () => ({
1515

1616
mock.module("next/navigation", () => ({
1717
redirect,
18+
usePathname: () => "/",
1819
notFound: () => {
1920
throw new Error("notFound");
2021
},

0 commit comments

Comments
 (0)