From 57541b48ba0402a8ff4a1e30c7e326fe9edab241 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bartek=20Iwa=C5=84czuk?= Date: Thu, 29 Aug 2024 00:56:15 +0100 Subject: test: replace usage of `window` with `globalThis` (#25284) Fixes several tests blocking https://github.com/denoland/deno/pull/25213 by replacing `window` global that is gone in Deno 2 with `globalThis`. Also adjusted a few tests using deprecated `rid` field. --- tests/testdata/import_attributes/dynamic_import.out | 1 - tests/testdata/import_attributes/dynamic_import.ts | 3 --- 2 files changed, 4 deletions(-) (limited to 'tests/testdata/import_attributes') diff --git a/tests/testdata/import_attributes/dynamic_import.out b/tests/testdata/import_attributes/dynamic_import.out index 01bc76c8a..7a7b4c91f 100644 --- a/tests/testdata/import_attributes/dynamic_import.out +++ b/tests/testdata/import_attributes/dynamic_import.out @@ -1,3 +1,2 @@ [WILDCARD] [Module: null prototype] { default: { a: "b", c: { d: 10 } } } -[Module: null prototype] { default: { a: "b", c: { d: 10 } } } diff --git a/tests/testdata/import_attributes/dynamic_import.ts b/tests/testdata/import_attributes/dynamic_import.ts index afff52e1a..093136fb0 100644 --- a/tests/testdata/import_attributes/dynamic_import.ts +++ b/tests/testdata/import_attributes/dynamic_import.ts @@ -1,6 +1,3 @@ const data1 = await import("./data.json", { with: { type: "json" } }); -// deno-lint-ignore no-import-assertions -const data2 = await import("./data.json", { assert: { type: "json" } }); console.log(data1); -console.log(data2); -- cgit v1.2.3