From a5f8798d7a718147de501c824f9c8969582cad2c Mon Sep 17 00:00:00 2001 From: Richard Lau Date: Sun, 22 Jan 2023 11:25:28 +0000 Subject: [PATCH] test: avoid left behind child processes MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Extend the Linux logic to all POSIX platforms in test-child-process-exec-abortcontroller-promisified. PR-URL: https://github.com/nodejs/node/pull/46276 Fixes: https://github.com/nodejs/build/issues/3154 Refs: https://github.com/nodejs/node/issues/37518 Reviewed-By: Moshe Atlow Reviewed-By: Beth Griggs Reviewed-By: Ruy Adorno Reviewed-By: Colin Ihrig Reviewed-By: Luigi Pinca Reviewed-By: Michaƫl Zasso Reviewed-By: Michael Dawson Reviewed-By: Rafael Gonzaga Reviewed-By: James M Snell --- .../test-child-process-exec-abortcontroller-promisified.js | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/test/parallel/test-child-process-exec-abortcontroller-promisified.js b/test/parallel/test-child-process-exec-abortcontroller-promisified.js index bf3c1c92b5ec21..bf8b69aa08b0b2 100644 --- a/test/parallel/test-child-process-exec-abortcontroller-promisified.js +++ b/test/parallel/test-child-process-exec-abortcontroller-promisified.js @@ -11,9 +11,9 @@ const invalidArgTypeError = { name: 'TypeError' }; -const waitCommand = common.isLinux ? - 'sleep 2m' : - `${process.execPath} -e "setInterval(()=>{}, 99)"`; +const waitCommand = common.isWindows ? + `${process.execPath} -e "setInterval(()=>{}, 99)"` : + 'sleep 2m'; { const ac = new AbortController();