-
Notifications
You must be signed in to change notification settings - Fork 123
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Multiple screen diff sections #416
Comments
BTW multiple image diffs are supported by Allure for a while allure-framework/allure2#1145 |
For some reason it doesn't work for me with |
that's because playwright by default doesn't support soft assertions. So we expect only one diff per test. It could (and probably will) be changed at some point, but for now I can only suggest crafting your own image diff attachments: testInfo.attach('Image Diff', {
body: Buffer.from(JSON.stringify({
actual: 'data:image/png;base64,' + actual.toString("base64"),
expected: 'data:image/png;base64,' + expected.toString("base64"),
diff: 'data:image/png;base64,' + diff.toString("base64")
})),
contentType: 'application/vnd.allure.image.diff'
}) |
Thanks for the tip, let me try. I'd really like to have it working out of the box! |
Just as a heads up, Soft assertions are coming with Playwright 1.19 microsoft/playwright#7819 |
@mxschmitt when do we expect to have this release |
We release every month, so probably in 2 weeks it's stable. |
Is your feature request related to a problem? Please describe.
I'd like to compare screenshots of multiple areas in the page within the same test.
At the moment only it should be only one diff per test otherwise screen diff section is not shown
Describe the solution you'd like
I'd like to see multiple collapsible screen diff entries ideally with the screenshot name
Describe alternatives you've considered
any other options to see multiple screen diffs per test
The text was updated successfully, but these errors were encountered: