diff --git a/src/test/index.ts b/src/test/index.ts index e963939224..075a70f5cd 100644 --- a/src/test/index.ts +++ b/src/test/index.ts @@ -251,8 +251,9 @@ export const test = _baseTest.extend file.endsWith('webm')); + const dirRetry = testInfo.outputPath('test-results', 'a-fail-chromium-retry1'); + const videoFailRetry = fs.readdirSync(dirRetry).find(file => file.endsWith('webm')); expect(videoFailRetry).toBeTruthy(); + + expect(result.report.suites[0].specs[1].tests[0].results[0].attachments).toEqual([]); + expect(result.report.suites[0].specs[1].tests[0].results[1].attachments).toEqual([{ + name: 'video', + contentType: 'video/webm', + path: path.join(dirRetry, videoFailRetry), + }]); }); test('should work with video size', async ({ runInlineTest }, testInfo) => {