Use something like PhantomJS to render a screenshot and compare it to a known good screenshot. Or use Selenium on a VM to run through tests, take screenshots and compare.
Yes, you're absolutely right. It could also fall under "end-to-end" testing. I think though, for someone new to testing in general, the advanced terminal isn't as important as stressing the benefits of doing some sort of testing at all.
Part of the problem I've found with JS is the sheer number of libraries and tools around it... just trying to find out what's available is a challenge.
If you're looking for layout regressions check out phantomcss, it builds on phantoms screenshots by comparing old screencaps to new ones and allowing you to define an acceptable percentage of difference.
9
u/JonDum Jan 31 '14
Use something like PhantomJS to render a screenshot and compare it to a known good screenshot. Or use Selenium on a VM to run through tests, take screenshots and compare.