summaryrefslogtreecommitdiff
path: root/tests/testdata/npm/import_json
diff options
context:
space:
mode:
Diffstat (limited to 'tests/testdata/npm/import_json')
-rw-r--r--tests/testdata/npm/import_json/main.js4
-rw-r--r--tests/testdata/npm/import_json/main.out10
2 files changed, 14 insertions, 0 deletions
diff --git a/tests/testdata/npm/import_json/main.js b/tests/testdata/npm/import_json/main.js
new file mode 100644
index 000000000..b752bdef8
--- /dev/null
+++ b/tests/testdata/npm/import_json/main.js
@@ -0,0 +1,4 @@
+import json from "npm:@denotest/binary-package@1/package.json" assert {
+ type: "json",
+};
+console.log(json);
diff --git a/tests/testdata/npm/import_json/main.out b/tests/testdata/npm/import_json/main.out
new file mode 100644
index 000000000..7db7ec4ea
--- /dev/null
+++ b/tests/testdata/npm/import_json/main.out
@@ -0,0 +1,10 @@
+{
+ name: "@denotest/binary-package",
+ version: "1.0.0",
+ main: "index.js",
+ optionalDependencies: {
+ "@denotest/binary-package-linux": "1.0.0",
+ "@denotest/binary-package-mac": "1.0.0",
+ "@denotest/binary-package-windows": "1.0.0"
+ }
+}