It'd be nice if the snapshots stored images as actual images instead of inline binary data.
Not sure if this is possible, I didn't see it documented anywhere.
It'd also be nice to add https://github.com/Huddle/Resemble.js built-in to do visual diffing with a threshold (which could be configured by ava config or test-specific).
Rather we might want to use https://github.com/gemini-testing/looks-same instead
@niftylettuce I have created ava + electron + visual regression test example.
I hope it will be helpful to you :)
@bokuweb cool! hmm yours checks for an exact match, I think I'm going to use @limonte approach at https://github.com/limonte/sweetalert2/blob/3c5b196fbf9bf3780c091a6e22a860228c9486ae/test/puppeteer/visual-tests.js#L167 probably, thank you. Currently using https://github.com/Huddle/Resemble.js and dislike that it requires canvas etc.
Would be cool if someone could submit a recipe for this: https://github.com/avajs/ava/tree/master/docs/recipes
Most helpful comment
@bokuweb cool! hmm yours checks for an exact match, I think I'm going to use @limonte approach at https://github.com/limonte/sweetalert2/blob/3c5b196fbf9bf3780c091a6e22a860228c9486ae/test/puppeteer/visual-tests.js#L167 probably, thank you. Currently using https://github.com/Huddle/Resemble.js and dislike that it requires canvas etc.