Skip to content

fix(html reporter): skip img bits with non-images#11188

Merged
pavelfeldman merged 1 commit intomicrosoft:mainfrom
rwoll:fix/suppress-image-diffs
Jan 5, 2022
Merged

fix(html reporter): skip img bits with non-images#11188
pavelfeldman merged 1 commit intomicrosoft:mainfrom
rwoll:fix/suppress-image-diffs

Conversation

@rwoll
Copy link
Copy Markdown
Member

@rwoll rwoll commented Jan 5, 2022

Regarding backwards compatibility: The image block will no longer show
up in cases where no extension is used (see test case), but I think this
is OK since you would have never hit the actual image comparison in the
test if you omitted an extension:

before.

Depending on how Visual Testing evolves, a follow up PR is due to clean
up references to images.

Fixes #11183

Regarding backwards compatibility: The image block will no longer show
up in cases where no extension is used (see test case), but I think this
is OK since you would have never hit the actual image comparison in the
test if you omitted an extension: https://github.com/microsoft/playwright/blob/328f3e265efe9c431ebae1ed3d7fd47dcd547b29/packages/playwright-test/src/matchers/golden.ts#L44 before.

Depending on how Visual Testing evolves, a follow up PR is due to clean
up regferences to images.

Fixes microsoft#11183

{expected && actual && <AutoChip header='Image mismatch'>
<ImageDiff actual={actual} expected={expected} diff={diff}></ImageDiff>
{expected && actual && <AutoChip header={`${hasImages ? 'Image' : 'Snapshot'} mismatch`}>
Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We leave this block since it is convenient to be able to download the expected/actual/diff attachments regardless of their content type.

@pavelfeldman pavelfeldman merged commit 3a4b7fa into microsoft:main Jan 5, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

[BUG] HTML Reporter: Image Mismatch Section Shows Even on non-Image Types

2 participants