diff options
Diffstat (limited to 'tests/registry/npm/@denotest/child-process-fork/1.0.0/index.js')
-rw-r--r-- | tests/registry/npm/@denotest/child-process-fork/1.0.0/index.js | 11 |
1 files changed, 3 insertions, 8 deletions
diff --git a/tests/registry/npm/@denotest/child-process-fork/1.0.0/index.js b/tests/registry/npm/@denotest/child-process-fork/1.0.0/index.js index 0482be404..ca0ba246a 100644 --- a/tests/registry/npm/@denotest/child-process-fork/1.0.0/index.js +++ b/tests/registry/npm/@denotest/child-process-fork/1.0.0/index.js @@ -1,14 +1,9 @@ const path = require("path"); +const childProcess = require("node:child_process"); function childProcessFork(path) { - const command = new Deno.Command(Deno.execPath(), { - args: ["run", "-A", path], - env: { - "DENO_DONT_USE_INTERNAL_NODE_COMPAT_STATE": Deno[Deno.internal].core.ops.op_npm_process_state(), - } - }); - const child = command.spawn(); - child.status.then(() => { + const child = childProcess.fork(path); + child.on("exit", () => { console.log("Done."); }); } |