Skip to content

Commit 7209066

Browse files
committed
Fix version check
1 parent 7a099db commit 7209066

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

packages/router/__tests__/navigation-test.ts

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -172,7 +172,8 @@ describe("navigations", () => {
172172

173173
// Node 18 and 20 output different errors here
174174
// Node 18 and 20 output different errors here
175-
let expected = process.version.startsWith("18")
175+
console.log("process.version", process.version);
176+
let expected = process.version.startsWith("v18")
176177
? "Unexpected token } in JSON at position 15"
177178
: "Unexpected non-whitespace character after JSON at position 15";
178179
expect(t.router.state.errors?.foo).toEqual(new SyntaxError(expected));
@@ -208,7 +209,7 @@ describe("navigations", () => {
208209
expect(t.router.state.loaderData).toEqual({});
209210

210211
// Node 18 and 20 output different errors here
211-
let expected = process.version.startsWith("18")
212+
let expected = process.version.startsWith("v18")
212213
? "Unexpected token } in JSON at position 15"
213214
: "Unexpected non-whitespace character after JSON at position 15";
214215
expect(t.router.state.errors?.root).toEqual(new SyntaxError(expected));

0 commit comments

Comments
 (0)