diff options
author | crowlKats <13135287+crowlKats@users.noreply.github.com> | 2021-04-10 00:12:00 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-04-10 00:12:00 +0200 |
commit | e7b7129b7a92b7500ded88f8f5baa25a7f59e56e (patch) | |
tree | 6716354fdd09b5b3ef37ec5769aa3ff4732fc039 /cli/tests/089_run_allow_list.ts | |
parent | 1c7217e3909c72135020ff415e61644e20e1f62c (diff) |
feat(permissions): allow run permission to take values (#9833)
This commit adds allowlist support to `--allow-run` flag.
Additionally `Deno.permissions.query()` allows to query for specific
programs within allowlist.
Diffstat (limited to 'cli/tests/089_run_allow_list.ts')
-rw-r--r-- | cli/tests/089_run_allow_list.ts | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/cli/tests/089_run_allow_list.ts b/cli/tests/089_run_allow_list.ts new file mode 100644 index 000000000..85c1730a1 --- /dev/null +++ b/cli/tests/089_run_allow_list.ts @@ -0,0 +1,13 @@ +try { + Deno.run({ + cmd: ["ls"], + }); +} catch (e) { + console.log(e); +} + +const proc = Deno.run({ + cmd: ["cat", "089_run_allow_list.ts"], + stdout: "null", +}); +console.log((await proc.status()).success); |