From 4e1ca1d1787f25ab9f0a72ccf9d8028f70b3a7ed Mon Sep 17 00:00:00 2001 From: Leo Kettmeir Date: Wed, 18 May 2022 22:00:11 +0200 Subject: refactor: use spawn API across codebase (#14414) --- cli/tests/testdata/089_run_allow_list.ts | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) (limited to 'cli/tests/testdata/089_run_allow_list.ts') diff --git a/cli/tests/testdata/089_run_allow_list.ts b/cli/tests/testdata/089_run_allow_list.ts index defb3196f..0eb79dcc2 100644 --- a/cli/tests/testdata/089_run_allow_list.ts +++ b/cli/tests/testdata/089_run_allow_list.ts @@ -1,13 +1,12 @@ try { - Deno.run({ - cmd: ["ls"], - }); + await Deno.spawn("ls"); } catch (e) { console.log(e); } -const proc = Deno.run({ - cmd: ["curl", "--help"], +const { status } = await Deno.spawn("curl", { + args: ["--help"], stdout: "null", + stderr: "inherit", }); -console.log((await proc.status()).success); +console.log(status.success); -- cgit v1.2.3