Skip to content

Commit

Permalink
cherry-pick(#33030): fix(ui): bring back the headed param
Browse files Browse the repository at this point in the history
  • Loading branch information
pavelfeldman committed Oct 10, 2024
1 parent 8d524e2 commit daff1a9
Showing 1 changed file with 5 additions and 4 deletions.
9 changes: 5 additions & 4 deletions packages/playwright/src/runner/testServer.ts
Original file line number Diff line number Diff line change
Expand Up @@ -302,10 +302,11 @@ export class TestServerDispatcher implements TestServerInterface {
preserveOutputDir: true,
reporter: params.reporters ? params.reporters.map(r => [r]) : undefined,
use: {
...(this._configCLIOverrides.use || {}),
trace: params.trace === 'on' ? { mode: 'on', sources: false, _live: true } : (params.trace === 'off' ? 'off' : undefined),
video: params.video === 'on' ? 'on' : (params.video === 'off' ? 'off' : undefined),
headless: params.headed ? false : undefined,
...this._configCLIOverrides.use,
...(params.trace === 'on' ? { trace: { mode: 'on', sources: false, _live: true } } : {}),
...(params.trace === 'off' ? { trace: 'off' } : {}),
...(params.video === 'on' || params.video === 'off' ? { video: params.video } : {}),
...(params.headed !== undefined ? { headless: !params.headed } : {}),
_optionContextReuseMode: params.reuseContext ? 'when-possible' : undefined,
_optionConnectOptions: params.connectWsEndpoint ? { wsEndpoint: params.connectWsEndpoint } : undefined,
},
Expand Down

0 comments on commit daff1a9

Please sign in to comment.