Skip to content

Commit

Permalink
npmBin needs js
Browse files Browse the repository at this point in the history
  • Loading branch information
tianfeng92 committed Sep 7, 2023
1 parent 638ab97 commit 8271d9b
Showing 1 changed file with 1 addition and 5 deletions.
6 changes: 1 addition & 5 deletions src/playwright-runner.ts
Original file line number Diff line number Diff line change
Expand Up @@ -287,11 +287,7 @@ async function runPlaywright(nodeBin: string, runCfg: RunnerConfig): Promise<Run
const metrics: Metrics[] = [];

// Define node/npm path for execution
let npmBin = path.join(path.dirname(nodeBin), 'npm');
if (os.platform() === 'win32') {
npmBin = path.join(path.dirname(nodeBin), 'npm.cmd');
}
console.log('npmBin: ', npmBin)
const npmBin = path.join(path.dirname(nodeBin), 'node_modules', 'npm', 'bin', 'npm-cli.js');
const nodeCtx = { nodePath: nodeBin, npmPath: npmBin };

// runCfg.path must be set for prepareNpmEnv to find node_modules. :(
Expand Down

0 comments on commit 8271d9b

Please sign in to comment.