From 88d760c55910fe68863c45b97ff9e65c157bb88d Mon Sep 17 00:00:00 2001 From: Rich Trott Date: Wed, 29 Dec 2021 15:06:21 -0800 Subject: [PATCH] benchmark: fix benchmark/run.js handling of --set run.js does not work with --set as it tries to include it as options to `fork()` rather than as part of argv for `fork()`. This doesn't throw an error because of a quirk in `fork()` that silently accepts arrays for options objects. This will be changing in Node.js 18.x. PR-URL: https://github.com/nodejs/node/pull/41334 Reviewed-By: Antoine du Hamel Reviewed-By: Luigi Pinca --- benchmark/run.js | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/benchmark/run.js b/benchmark/run.js index aa7c71bdd4ecd3..a3c9da12f8b9c8 100644 --- a/benchmark/run.js +++ b/benchmark/run.js @@ -42,8 +42,7 @@ if (format === 'csv') { const filename = benchmarks[i]; const child = fork( path.resolve(__dirname, filename), - cli.test ? ['--test'] : [], - cli.optional.set + cli.test ? ['--test'] : cli.optional.set ); if (format !== 'csv') {