diff options
Diffstat (limited to 'test/js/deno/scripts/postinstall.ts')
-rw-r--r-- | test/js/deno/scripts/postinstall.ts | 11 |
1 files changed, 3 insertions, 8 deletions
diff --git a/test/js/deno/scripts/postinstall.ts b/test/js/deno/scripts/postinstall.ts index 4031b29df..bca1e6582 100644 --- a/test/js/deno/scripts/postinstall.ts +++ b/test/js/deno/scripts/postinstall.ts @@ -5,21 +5,16 @@ import tests from "../resources/tests.json"; for (const test of tests) { const path = join(import.meta.dir, "..", test.path); - const url = new URL( - test.remotePath, - "https://raw.githubusercontent.com/denoland/deno/main/cli/tests/" - ); + const url = new URL(test.remotePath, "https://raw.githubusercontent.com/denoland/deno/main/cli/tests/"); const response = await fetch(url); console.log(response.status, url.toString(), "->", test.path); if (!response.ok) { - throw new Error( - `Failed to download from GitHub: ${url} [status: ${response.status}]` - ); + throw new Error(`Failed to download from GitHub: ${url} [status: ${response.status}]`); } let body = await response.text(); for (const query of imports) { const pattern = new RegExp(`"(.*${query})"`, "gmi"); - body = body.replace(pattern, "\"deno:harness\""); + body = body.replace(pattern, '"deno:harness"'); } const src = `// Updated: ${response.headers.get("Date")} // URL: ${url} |