Updating to Selenium 3 with Firefox

I struggled a bit with updating Selenium from 2.53 to 3.3.1, so I thought about documenting the steps. I’m going to skip any background trivia and get to the point. I’m assuming you are on Windows.

What you’ll need:

Now to run the tests you need to tell Selenium where to find the Firefox driver. To do this we are going to create a bat script, let’s be creative and call it selenium.bat. Insert copy paste the following into the selenium.bat:

java -jar -Dwebdriver.gecko.driver=geckodriver.exe selenium-server-standalone-3.3.1.jar

Obviously the geckodriver.exe, selenium JAR and the bat script need to be in the same folder. Just run the bat file and you’re ready to start updating your tests  🙂