This commit is contained in:
Simon Knott 2024-10-16 12:12:33 +02:00
parent 97c11e4940
commit 0e9eaf2134
No known key found for this signature in database
GPG key ID: 8CEDC00028084AEC

View file

@ -903,8 +903,8 @@ for (const useIntermediateMergeReport of [false] as const) {
body: Buffer.from('<h1>step attachment</h1>'), body: Buffer.from('<h1>step attachment</h1>'),
}); });
await testInfo.attach('foo', { body: 'a' }); await testInfo.attach('foo', { body: 'body-a' });
await testInfo.attach('foo', { body: 'b' }); await testInfo.attach('foo', { body: 'body-b' });
}); });
}); });
`, `,
@ -921,7 +921,13 @@ for (const useIntermediateMergeReport of [false] as const) {
await testSteps.getByText('step with attachment').click(); await testSteps.getByText('step with attachment').click();
await expect(testSteps.getByText('attach "foo"'), 'uses normal rendering when it cannot correlate by name').toHaveCount(2); await expect(testSteps).not.toContainText('body-a');
await testSteps.getByText('foo').nth(0).click();
await expect(testSteps).toContainText('body-a');
await expect(testSteps).not.toContainText('body-b');
await testSteps.getByText('foo').nth(1).click();
await expect(testSteps).toContainText('body-b');
const [newTab] = await Promise.all([ const [newTab] = await Promise.all([
page.waitForEvent('popup'), page.waitForEvent('popup'),