3 ms·
A nice way to do a quick visual regression test on the command line: cmp -s <( cutycapt devserver.com/somepage ) \ <( cutycapt liveserver.com/s
by no_gravity 8y ago
A nice way to do a quick visual regression test on the command line:
cmp -s <( cutycapt devserver.com/somepage ) \
<( cutycapt liveserver.com/somepage )
At Product Chart, we use this in a small bash script that reads a config file with a list of pages and tests them all for regressions:
https://www.productchart.com/blog/2015-07-19-urldiff https://www.productchart.com/blog/2015-07-19-urldiff
- Ulrich1 8y agoNice link, this is an interesting blog post. But note that Kantu does much more than just binary screenshot comparisons: Kantu allows you to select specific areas of the website to test, and - especially important - the image comparison is error-tolerant. That means that (smaller) changes in image and font rendering do not break the test. So a test case created on the Mac works on Linux and Windows as well. In this respect it is similar to Sikuli (http://www.sikuli.org/ http://www.sikuli.org/ ) - but all inside a Chrome and Firefox browser extension, with no external installations required. Edit: More info about the choice of WASM for image search here: https://news.ycombinator.com/item?id=17574862 https://news.ycombinator.com/item?id=17574862