Rails acceptance testing with Virtual Machines

I often test software on Vagrant virtual machines. Sometimes however they use real browsers and require some X server running. This is often the case when using Cucumber, Capybara, Selenium and Firefox. When everything is running smoothly we usually use at +Arkency  one of this:

xvfb-run -a bundle exec rake cucumber
xvfb-run -a bundle exec cucumber features/name.feature:line_number

It is however sometimes useful to see the tests being executed. For that I use:

Xvfb -screen 0 1280x1024x24 -ac
DISPLAY=:0 ratpoison
x11vnc -display :0
DISPLAY=:0 bundle exec rake cucumber

And connect to the Vagrant machine using Vinagre.

Popularne posty z tego bloga

Faster rails development part 2 - Annoucing Active Reload