Selenium / Watir on cloud9



I’m trying to run a very simple code, just to test the behaviour of C9 with watir gem.

browser = 
browser.goto ""

When I run it I have the follow error:

Selenium::WebDriver::Error::WebDriverError: unable to obtain stable firefox connection in 60 seconds (

I googled it, but it seens that C9 does not support headless Selenium browser.
Can anyone confirm or give some hint to run Selenium?


I tried to install chromewebdriver-helper and use chrome as the browser.

A chrome error raised:
unknown error: Chrome failed to start: exited abnormally

I checked the gem versions and all gems (‘watir-webdriver’, ‘selenium-webdriver’, ‘chromedriver-helper’ ) are updated.

It seens that C9 does not suport Selenium.


Is this Selenium thing some sort of server? If so, you’ll need to bind it to the ip and one of the 3 open ports, 8080, 8081, and 8082. Without these ports, it will not communicate to the outside world.


Usually you run headless browser instances using xvfb so you might want to give that a try. I personally had no luck getting that to work on cloud9, and ended up swapping out selenium for poltergeist which uses phantomjs as a headless webkit.


I was able to test js using firefox and xvfb
sudo apt-get install firefox xvfb
2) Run tests (prepend condole command with xvfb-run)
xvfb-run bin/rspec spec/features/