summaryrefslogtreecommitdiff
path: root/cli/tests/testdata/npm/registry
diff options
context:
space:
mode:
authorDavid Sherret <dsherret@users.noreply.github.com>2023-08-01 18:47:57 -0400
committerGitHub <noreply@github.com>2023-08-01 18:47:57 -0400
commit00b5fe8ba31240f6e6abf668ebda8ed0c40fb524 (patch)
tree466a5940ef057e616a63a3d6936f0d31cd48d2b4 /cli/tests/testdata/npm/registry
parent51ceed860b6f562c70fb09ae1c7173a9eb14473c (diff)
feat(npm): support running non-bin scripts in npm pkgs via `deno run` (#19975)
Closes https://github.com/denoland/deno/issues/19967
Diffstat (limited to 'cli/tests/testdata/npm/registry')
-rw-r--r--cli/tests/testdata/npm/registry/@denotest/bin/0.6.0/cli-cjs.js5
-rw-r--r--cli/tests/testdata/npm/registry/@denotest/bin/0.6.0/cli.mjs5
-rw-r--r--cli/tests/testdata/npm/registry/@denotest/bin/0.6.0/package.json4
3 files changed, 14 insertions, 0 deletions
diff --git a/cli/tests/testdata/npm/registry/@denotest/bin/0.6.0/cli-cjs.js b/cli/tests/testdata/npm/registry/@denotest/bin/0.6.0/cli-cjs.js
new file mode 100644
index 000000000..7b6ba2724
--- /dev/null
+++ b/cli/tests/testdata/npm/registry/@denotest/bin/0.6.0/cli-cjs.js
@@ -0,0 +1,5 @@
+const process = require("process");
+
+for (const arg of process.argv.slice(2)) {
+ console.log(arg);
+}
diff --git a/cli/tests/testdata/npm/registry/@denotest/bin/0.6.0/cli.mjs b/cli/tests/testdata/npm/registry/@denotest/bin/0.6.0/cli.mjs
new file mode 100644
index 000000000..0ae8e9190
--- /dev/null
+++ b/cli/tests/testdata/npm/registry/@denotest/bin/0.6.0/cli.mjs
@@ -0,0 +1,5 @@
+import process from "node:process";
+
+for (const arg of process.argv.slice(2)) {
+ console.log(arg);
+}
diff --git a/cli/tests/testdata/npm/registry/@denotest/bin/0.6.0/package.json b/cli/tests/testdata/npm/registry/@denotest/bin/0.6.0/package.json
new file mode 100644
index 000000000..db50464bc
--- /dev/null
+++ b/cli/tests/testdata/npm/registry/@denotest/bin/0.6.0/package.json
@@ -0,0 +1,4 @@
+{
+ "name": "@deno/bin",
+ "version": "0.6.0"
+}