diff options
Diffstat (limited to 'tests/specs/compile/jsr_with_deps')
-rw-r--r-- | tests/specs/compile/jsr_with_deps/__test__.jsonc | 22 | ||||
-rw-r--r-- | tests/specs/compile/jsr_with_deps/main.out | 2 | ||||
-rw-r--r-- | tests/specs/compile/jsr_with_deps/main.ts | 8 |
3 files changed, 32 insertions, 0 deletions
diff --git a/tests/specs/compile/jsr_with_deps/__test__.jsonc b/tests/specs/compile/jsr_with_deps/__test__.jsonc new file mode 100644 index 000000000..be2bbd1e4 --- /dev/null +++ b/tests/specs/compile/jsr_with_deps/__test__.jsonc @@ -0,0 +1,22 @@ +{ + "tempDir": true, + "steps": [{ + "if": "unix", + "args": "compile --output main main.ts", + "output": "[WILDCARD]" + }, { + "if": "unix", + "commandName": "./main", + "args": [], + "output": "main.out" + }, { + "if": "windows", + "args": "compile --output main.exe main.ts", + "output": "[WILDCARD]" + }, { + "if": "windows", + "commandName": "./main.exe", + "args": [], + "output": "main.out" + }] +} diff --git a/tests/specs/compile/jsr_with_deps/main.out b/tests/specs/compile/jsr_with_deps/main.out new file mode 100644 index 000000000..6340327e0 --- /dev/null +++ b/tests/specs/compile/jsr_with_deps/main.out @@ -0,0 +1,2 @@ +[Function: join] +http://[WILDLINE]/@std/url/0.220.1/join.ts diff --git a/tests/specs/compile/jsr_with_deps/main.ts b/tests/specs/compile/jsr_with_deps/main.ts new file mode 100644 index 000000000..44a7dc08c --- /dev/null +++ b/tests/specs/compile/jsr_with_deps/main.ts @@ -0,0 +1,8 @@ +// this was previously hanging in deno compile and wouldn't work +import { join } from "jsr:@std/url@0.220/join"; +import "jsr:@std/url@0.220/normalize"; + +console.log(join); + +// ensure import.meta.resolve works in compile for jsr specifiers +console.log(import.meta.resolve("jsr:@std/url@0.220/join")); |