@@ -239,7 +239,7 @@ const playwrightFixtures: Fixtures<TestFixtures, WorkerFixtures> = ({
239239
240240 _snapshotSuffix : [ process . platform , { scope : 'worker' } ] ,
241241
242- _setupContextOptionsAndArtifacts : [ async ( { playwright, _snapshotSuffix, _combinedContextOptions, _artifactsDir, trace, screenshot, actionTimeout, navigationTimeout, testIdAttribute } , use , testInfo ) => {
242+ _setupContextOptionsAndArtifacts : [ async ( { playwright, _contextReuseMode , _snapshotSuffix, _combinedContextOptions, _artifactsDir, trace, screenshot, actionTimeout, navigationTimeout, testIdAttribute } , use , testInfo ) => {
243243 if ( testIdAttribute )
244244 playwrightLibrary . selectors . setTestIdAttribute ( testIdAttribute ) ;
245245 testInfo . snapshotSuffix = _snapshotSuffix ;
@@ -251,7 +251,7 @@ const playwrightFixtures: Fixtures<TestFixtures, WorkerFixtures> = ({
251251 const traceMode = normalizeTraceMode ( trace ) ;
252252 const defaultTraceOptions = { screenshots : true , snapshots : true , sources : true } ;
253253 const traceOptions = typeof trace === 'string' ? defaultTraceOptions : { ...defaultTraceOptions , ...trace , mode : undefined } ;
254- const captureTrace = shouldCaptureTrace ( traceMode , testInfo ) ;
254+ const captureTrace = shouldCaptureTrace ( traceMode , testInfo ) && ! process . env . PW_TEST_DISABLE_TRACING ;
255255 const temporaryTraceFiles : string [ ] = [ ] ;
256256 const temporaryScreenshots : string [ ] = [ ] ;
257257 const testInfoImpl = testInfo as TestInfoImpl ;
@@ -603,7 +603,7 @@ type ParsedStackTrace = {
603603 apiName : string ;
604604} ;
605605
606- export function normalizeVideoMode ( video : VideoMode | 'retry-with-video' | { mode : VideoMode } | undefined ) : VideoMode {
606+ function normalizeVideoMode ( video : VideoMode | 'retry-with-video' | { mode : VideoMode } | undefined ) : VideoMode {
607607 if ( ! video )
608608 return 'off' ;
609609 let videoMode = typeof video === 'string' ? video : video . mode ;
@@ -616,7 +616,7 @@ function shouldCaptureVideo(videoMode: VideoMode, testInfo: TestInfo) {
616616 return ( videoMode === 'on' || videoMode === 'retain-on-failure' || ( videoMode === 'on-first-retry' && testInfo . retry === 1 ) ) ;
617617}
618618
619- export function normalizeTraceMode ( trace : TraceMode | 'retry-with-trace' | { mode : TraceMode } | undefined ) : TraceMode {
619+ function normalizeTraceMode ( trace : TraceMode | 'retry-with-trace' | { mode : TraceMode } | undefined ) : TraceMode {
620620 if ( ! trace )
621621 return 'off' ;
622622 let traceMode = typeof trace === 'string' ? trace : trace . mode ;
0 commit comments