Learn how to download the best Selenium version for you

Selenium WebDriver is one of the most popular browser-based test automation tools out there, providing an easy way of automatically interacting with websites using a multitude of browsers, from Chrome and Firefox to good old Internet Explorer.

Its flexibility in terms of programming languages that it can be used with, not to mention the wide array of support found online make it the best choice if you’re trying to test out any web application.

Given the project’s long history, however, it can be a bit tricky to figure out just which version to use, not to mention how to download or install it. This article will explain the differences between the old and new Selenium versions, as well as how to get the version most suitable for your web automation project.

Selenium versions and their purpose 🔎

Browsing the official SeleniumHQ page, you can see that there are two main versions of Selenium – IDE and WebDriver.

Selenium IDE is available just as an extension for the Mozilla Firefox and Google Chrome web browsers. It can help in exploratory testing but, if you are serious about automating your web application, it will soon prove inefficient.

Selenium WebDriver is the much more important version of the popular tool, as it includes a variety of methods through which you can “drive” (as in control) a browser. These methods are translated in a variety of programming languages, from Java to JavaScript, Ruby, C#, and Python.

There’s also Selenium Server, which is useful when running tests written with WebDriver on a cloud-based platform. It can also be used to emulate the functions of the older, now deprecated Selenium Grid. Besides Grid, another now outdated version is Selenium Remote Control (RC).

Download the right version for you 🔀

On the official download page, you can see several listings that can help you in your automation journey but it can get confusing. Fortunately, here’s a brief overview of every option, as of January 2019.

Selenium Standalone Server

This version is useful only when running tests written with WebDriver on a cloud platform. If you’re just running the tests on a single machine, either your own or through Jenkins, this version won’t be of uses.

The Internet Explorer Driver Server

Like it or not, Internet Explorer is still a very popular web browser, so you may have to include tests that verify your website’s performance when displayed in it. This server, once downloaded, needs to be added to your system’s PATH. In case you don’t know how to do that, follow the steps below.

You can do this by running the following commands, replacing PATH_TO_YOUR_IE_ DRIVER_FOLDER with your actual path, for example C:\IEDriverServer_x64_3.14.0\IEDriverServer.exe:

  • Open the Start menu
  • Type Environment and select the option to Edit System Variables
  • A new window should appear with options for Performance, User Profiles, and so on. Press the button marked Environment Variables
  • In this new window, in the System Variables section, select the Path variable and press Edit.
  • Depending on the Windows version, you’ll see a long list of paths separated by semi-colon (;) or a table with the values on each row.
  • Add the PATH_TO_YOUR_IE_ DRIVER_FOLDER at the end of the list or on a new row and hit OK.

Selenium Client & WebDriver Language Bindings

This is the most important section of the download page, as you’ll be using the WebDriver bindings to actually write your automated tests. There are multiple versions depending on the programming language you’re writing your tests in. The core languages are Java, C#, Ruby, Python, and JavaScript. Thanks to the great community, there are also user-made versions for languages like Perl, PHP, R, and much more. These, however, are not developed or supported officially by SeleniumHQ.

It’s important to note that some of the official languages have multiple ways of obtaining the latest version of Selenium WebDriver.

For Java, you can download a .zip archive that contains the .jar files needed to use Selenium WebDriver’s methods in your own classes. However, the preferred way to get it is through Maven. In case you’re not familiar with the build management tool, you can read our own introduction for beginners to Maven.

For C# you can also download a .zip archive but, once again, there is a preferredway, by using the NuGet service, which is linked further down the page.

The Ruby, Python, and JavaScript download links take you to those languages’ official repositories, in the form of RubyGems, PyPi, and NPM.

SafariDriver Deprecation and Apple’s Official SafariDriver

SeleniumHQ made a version of SafariDriver that enables WebDriver to interact with the browser on Apple platforms like Mac or iOS. However, in recent years the old implementation has been deprecated, replaced with a proprietary version made by Apple. You can read all about it on Apple’s developer documentation.

Selenium IDE

I already talked about Selenium IDE, the extension for Chrome and Firefox. While it may be enough to record and play some website interactions, trying to do anything complex shows the limitations of the tool.

Third Party Browser Drivers

This is another important section of the downloads, as besides Selenium WebDriver, you need an actual browser driver that transfers the commands to the actual browser executable. To get a better idea, check out the diagram below.

The Selenium WebDriver lifecycle
The Selenium WebDriver lifecycle

In the example above, I start out with commands that I want to be executed as part of my test. I then write Java code that uses methods from the Selenium WebDriver library. I then use the ChromeDriver executable to transmit the Selenium commands to an instance of the Google Chrome browser.

In this section, you can download drivers for most popular browsers, starting with Firefox and Chrome and continuing to Edge or Safari. You also have options for lesser known browsers, but you’ll probably stick to the more important ones.

Third Party Language Bindings

If you want to use Selenium WebDriver with other programming languages besides the officially-supported ones, you can try the community-made bindings listed in this section.

Selenium IDE Plugins

This final section includes a wide variety of plugins that help Selenium IDE, the browser extension, perform more tasks.

Conclusion 🏁

I hope that you now know a bit more about all the different Selenium options and downloads that the official website throws at you. More articles are coming about how to get started with Selenium, but at least you will be ready to start, now that you know what to download and what can be useful for you.

Leave a Reply

Your email address will not be published. Required fields are marked *