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/integration_tests.rs | |
| 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/integration_tests.rs')
| -rw-r--r-- | cli/tests/integration_tests.rs | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/cli/tests/integration_tests.rs b/cli/tests/integration_tests.rs index 310cb3289..2d4d8995e 100644 --- a/cli/tests/integration_tests.rs +++ b/cli/tests/integration_tests.rs @@ -2846,6 +2846,21 @@ console.log("finish"); output: "088_dynamic_import_already_evaluating.ts.out", }); + itest!(_089_run_allow_list { + args: "run --allow-run=cat 089_run_allow_list.ts", + output: "089_run_allow_list.ts.out", + }); + + #[cfg(unix)] + #[test] + fn _090_run_permissions_request() { + let args = "run 090_run_permissions_request.ts"; + let output = "090_run_permissions_request.ts.out"; + let input = b"g\nd\n"; + + util::test_pty(args, output, input); + } + itest!(js_import_detect { args: "run --quiet --reload js_import_detect.ts", output: "js_import_detect.ts.out", |
