summaryrefslogtreecommitdiff
path: root/cli/tests/testdata/no_prompt.ts
diff options
context:
space:
mode:
authorNayeem Rahman <nayeemrmn99@gmail.com>2022-04-18 20:08:30 +0100
committerGitHub <noreply@github.com>2022-04-18 21:08:30 +0200
commit66fbdd2ed4b5ecab8a51278cd76bce7adedb4fc2 (patch)
tree55e38ace63362cb49ac8cf9a5f66594a04770335 /cli/tests/testdata/no_prompt.ts
parentbf804d3ffff39dab3c7fc8a1a91538ec51276223 (diff)
feat: Add DENO_NO_PROMPT variable (#14209)
This commit adds support for "DENO_NO_PROMPT" env variable, that can be used instead of "--no-prompt" flag to completely disable permission prompts.
Diffstat (limited to 'cli/tests/testdata/no_prompt.ts')
-rw-r--r--cli/tests/testdata/no_prompt.ts10
1 files changed, 10 insertions, 0 deletions
diff --git a/cli/tests/testdata/no_prompt.ts b/cli/tests/testdata/no_prompt.ts
new file mode 100644
index 000000000..88dccc458
--- /dev/null
+++ b/cli/tests/testdata/no_prompt.ts
@@ -0,0 +1,10 @@
+new Worker("data:,setTimeout(() => Deno.exit(2), 200)", {
+ type: "module",
+ deno: { namespace: true },
+});
+
+try {
+ await Deno.run({ cmd: ["ps"] });
+} catch {
+ Deno.exit(0);
+}