Add --allow-read (#1689)

Co-authored-by: Greg Altman <g.s.altman@gmail.com>
This commit is contained in:
Dmitry Sharshakov 2019-02-08 23:59:38 +03:00 committed by Ryan Dahl
parent 3abaf9edb6
commit 9ab03389f0
25 changed files with 395 additions and 118 deletions

View file

@ -18,7 +18,9 @@ def fmt_test(deno_exe):
# Set DENO_DIR to //js/ so we don't have to rely on an intenet
# connection to download https://deno.land/x/std/prettier/main.ts
deno_dir = os.path.join(root_path, "js")
run([deno_exe, dst, "--fmt"], merge_env={"DENO_DIR": deno_dir})
run(
[deno_exe, dst, "--fmt", "--allow-read"],
merge_env={"DENO_DIR": deno_dir})
with open(fixed_filename) as f:
expected = f.read()
with open(dst) as f:
@ -31,4 +33,3 @@ def fmt_test(deno_exe):
if __name__ == "__main__":
fmt_test(sys.argv[1])