From fd4a30546446187b7abb94dc5c9e0b8443bcffa6 Mon Sep 17 00:00:00 2001 From: john-mcinall <66478643+john-mcinall@users.noreply.github.com> Date: Fri, 10 Nov 2023 17:46:55 +0000 Subject: [PATCH] test: replace forEach with for of PR-URL: https://github.com/nodejs/node/pull/50602 Reviewed-By: Rafael Gonzaga Reviewed-By: Benjamin Gruenbaum Reviewed-By: Luigi Pinca --- test/parallel/test-runner-cli.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/test/parallel/test-runner-cli.js b/test/parallel/test-runner-cli.js index 34ce67caa5e6a5..ab6078a4a05d74 100644 --- a/test/parallel/test-runner-cli.js +++ b/test/parallel/test-runner-cli.js @@ -104,7 +104,7 @@ const testFixtures = fixtures.path('test-runner'); ['--print', 'console.log("should not print")', '--test'], ]; - flags.forEach((args) => { + for (const args of flags) { const child = spawnSync(process.execPath, args); assert.notStrictEqual(child.status, 0); @@ -112,7 +112,7 @@ const testFixtures = fixtures.path('test-runner'); assert.strictEqual(child.stdout.toString(), ''); const stderr = child.stderr.toString(); assert.match(stderr, /--test/); - }); + } } {