question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Image snapshots do not match "Expected image to be the same size as the snapshot.."

See original GitHub issue

First of all, thanks for this awesome html reporter!

I get this issue when the image snapshot fails for a different error and this doesn’t get picked up by the matcher in jest-stare so the snapshot diff is not copied and rendered. Error: Expected image to be the same size as the snapshot (2370x6290), but was different (2370x6330).

Relevant code line: https://github.com/dkelosky/jest-stare/blob/ac83ee473cfefb5e94a2569b681118372cbf14eb/src/render/diff/ImageSnapshotDifference.ts#L12

It just needs to additionally match against Expected image to be the same size as the snapshot.

Thanks.

Issue Analytics

  • State:closed
  • Created 4 years ago
  • Comments:5 (3 by maintainers)

github_iconTop GitHub Comments

2reactions
dkeloskycommented, Apr 5, 2019

fixed by #77 and published @1.13.2, thanks!

1reaction
dkeloskycommented, Apr 5, 2019

Thats great, thank you! I assume you cloned this repo to make your branch. Instead, please fork the repo, open a branch, push there, and then open the PR.

Read more comments on GitHub >

github_iconTop Results From Across the Web

jest-image-snapshot - npm
Jest matcher for image comparisons. Most commonly used for visual regression testing.. Latest version: 6.1.0, last published: 23 days ago.
Read more >
Automated visual regression testing with TypeScript ... - Medium
Error: Expected image to match or be a close match to snapshot but was 0.0005804554357724534% different from snapshot (2.7861860917077763 ...
Read more >
Visual Testing - Cypress Documentation
This open source plugin compares the baseline and the current images side by side if pixel difference is above the threshold; notice how...
Read more >
Image Comparison (Visual Regression Testing) Service
A resized Chrome or Safari is not equal to what your enduser is using on his mobile phone. Web-pages and so on a...
Read more >
Snapshot Testing - Jest
The test will fail if the two snapshots do not match: either the change is ... Also, rendering the same component with different...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found