Skip to content

Commit

Permalink
feat: passthrough test runner args after --
Browse files Browse the repository at this point in the history
  • Loading branch information
mdjastrzebski committed Aug 28, 2024
1 parent 7ed32ab commit 9a7af35
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions packages/cli/src/commands/measure.ts
Original file line number Diff line number Diff line change
Expand Up @@ -56,13 +56,13 @@ export async function run(options: MeasureOptions) {
return;
}

const baseTestRunnerArgs = process.env.TEST_RUNNER_ARGS ?? buildDefaultTestRunnerArgs(options);
const passthroughArgs = options._ ?? [];
const baseRunnerArgs = process.env.TEST_RUNNER_ARGS ?? buildDefaultTestRunnerArgs(options);
const passthroughRunnerArgs = options._ ?? [];

const nodeMajorVersion = getNodeMajorVersion();
logger.verbose(`Node.js version: ${nodeMajorVersion} (${process.versions.node})`);

const nodeArgs = [...getNodeFlags(nodeMajorVersion), testRunnerPath, baseTestRunnerArgs, ...passthroughArgs];
const nodeArgs = [...getNodeFlags(nodeMajorVersion), testRunnerPath, baseRunnerArgs, ...passthroughRunnerArgs];
logger.verbose('Running tests using command:');
logger.verbose(`$ node \\\n ${nodeArgs.join(' \\\n ')}\n`);

Expand Down

0 comments on commit 9a7af35

Please sign in to comment.