@@ -335,6 +335,16 @@ async function writePreflight(artifactBase: string) {
335335 ) ;
336336}
337337
338+ async function writeSkippedVisualProof ( logPath : string ) {
339+ const startedAt = Date . now ( ) ;
340+ await writeText ( logPath , "blocked: --skip-visual-proof was set\n" ) ;
341+ return {
342+ failureReason : "--skip-visual-proof was set" ,
343+ status : "blocked" as const ,
344+ wallMs : Date . now ( ) - startedAt ,
345+ } ;
346+ }
347+
338348function isMissingManagedPlaywrightBrowser ( error : unknown ) {
339349 const message = error instanceof Error ? error . message : String ( error ) ;
340350 return (
@@ -389,7 +399,11 @@ async function captureControlUiScreenshot(params: {
389399 logPath : string ;
390400 repoRoot : string ;
391401 screenshotPath : string ;
402+ skipVisualProof : boolean ;
392403} ) {
404+ if ( params . skipVisualProof ) {
405+ return writeSkippedVisualProof ( params . logPath ) ;
406+ }
393407 const startedAt = Date . now ( ) ;
394408 try {
395409 const { browser } = await launchUxMatrixChromium ( ) ;
@@ -519,15 +533,10 @@ async function captureProducerArtifactFixtureProof(params: {
519533 skipVisualProof : boolean ;
520534 videoPath : string ;
521535} ) {
522- const startedAt = Date . now ( ) ;
523536 if ( params . skipVisualProof ) {
524- await writeText ( params . logPath , "blocked: --skip-visual-proof was set\n" ) ;
525- return {
526- failureReason : "--skip-visual-proof was set" ,
527- status : "blocked" as const ,
528- wallMs : Date . now ( ) - startedAt ,
529- } ;
537+ return writeSkippedVisualProof ( params . logPath ) ;
530538 }
539+ const startedAt = Date . now ( ) ;
531540 try {
532541 const videoDir = path . join ( path . dirname ( params . videoPath ) , "recording" ) ;
533542 await fs . mkdir ( videoDir , { recursive : true } ) ;
@@ -671,6 +680,7 @@ export async function runUxMatrixEvidenceProducer(options: ProducerOptions) {
671680 logPath : path . join ( screenshotCellDir , "logs.txt" ) ,
672681 repoRoot : options . repoRoot ,
673682 screenshotPath : matrixScreenshotPath ,
683+ skipVisualProof : options . skipVisualProof ,
674684 } ) ;
675685
676686 const initialCells : MatrixCell [ ] = [
0 commit comments