A couple of things have worked well. First of all, I’ve added capybara-screenshot gem to my cucumber tests – setting it up was as simple as adding it to the gemfile and putting one line in the env.rb for my tests:
The next step was accessing the details of the fails on the build. I’m using Codeship which is an awesome cloud-based CI platform that offers 100 builds a month for FREE (plenty for a solo developer on a startup!) Codeship allows me to create a debug build and access it via SSH, which was great because now I can generate images and HTML from the failed tests.
The last problem to solve was getting the images. There’s probably a few ways to skin this cat – I started off just using the HTML, but a picture not only tells a thousand words, it usually is a much faster way of seeing the root of the problem than picking through the HTML code. Turns out SFTP works perfectly – I just use the server IP and port from the SSH command that Codeship provides:
sftp -P [port number] user@ip_address get [image file name]
I do still need to ssh in and run the failing tests, but finally I can see the broken screens! Much faster.