Selenium WebDriver with Ruby: Troubleshooting
Last updated:upon running a script, a blank browser window shows up but it doesn't navigate anywhere (Firefox driver)
One of the reasons for this may be an upgraded version of Firefox that isn't supported by the gem version you're currently using, so update selenium-webdriver
gem:
$ sudo gem update
a css selector you know for sure is correct does not work
If you have a selector in your code and know for sure it is correct but you geet getting a "Unable to locate element"
with the following exception:
Selenium::WebDriver::Error::NoSuchElementError
Then you may need to kill the browser process and open a new browser window: on linux, this is what I do ( I run selenium with the Firefox Driver)
$ sudo killall firefox
Then I open a new Firefox window, wait for it to load, and close it. This seems to put selenium back into working order.