As we know that Selenium is one of the leaders in the market of Web Automation Tools, and WebDriver is one of the essential members of the Selenium family, which provides various capabilities to simulate the user behaviors on the Web Applications. With the enhancement of programming languages and vast horizon available for the development of Web applications, Selenium has also expanded its wings. Additionally, it has provided its bindings/libraries in various programming languages, so as the users can develop their test cases in the programming language of their choice. As here we are majorly covering the usage of Selenium in JAVA, we will be covering the details of how to download the Selenium WebDriver for JAVA only.
Now, as we know that, to kickstart the automation journey using Selenium and JAVA, we majorly need three pre-requisites:
- Installing and Setting up JAVA
- Installing and Setting up an IDE, such as Eclipse
- Downloading Selenium WebDriver
In this article, we will be covering the details for the 3rd essential pre-requisite, which is downloading the Selenium WebDriver for the corresponding platform. We will be covering the details of downloading the Selenium WebDriver for following platforms:
- How to download Selenium WebDriver for Java on Windows?
- Similarly, how to download Selenium WebDriver for Java on macOS?
How to download Selenium WebDriver for Java on Windows?
Every programming language that selenium supports has its client driver. Since we are configuring Selenium with Java, we will need ‘WebDriver Java client.’ All you need to do is follow the steps as mentioned below, and you will have all the pre-requisites ready for writing your selenium tests using Java.
1. Firstly, you can download the WebDriver java client from the official Selenium website. After that, click on the Download link for the Java driver.
You can see that the table identifies the various Selenium Webdriver client bindings along with the updates corresponding to them. You can refer below description to understand what each of these table headings implies:
- Language- The core programming languages bindings supported are as a list in column 1 of the table.
- Stable Version- This column implies the last stable version corresponding to the language binding.
- Release Date- The date of release of the stable version displays under this column.
- Alpha Version- The very early version of the next major update is the Alpha version. The alpha version for the selenium language bindings also exists in the table.
- Alpha Release Date- Just like the regular release date, the alpha release date marks the date of release of the Alpha version.
- Links- The links to download the language bindings, alpha version bindings, API Documentation, and changelogs are under the links column.
Note: As the Selenium 4 Alpha has already launched, there is an explicit link in the last column to download the Selenium 4 Alpha binding. Consequently, to download the Alpha version, you need to click on the link highlighted in the screenshot below:
For this article, we will be downloading the stable version only. Therefore, we will be clicking on the Download button, which will download the corresponding zip file for the latest stable version of Selenium WebDriver.
2. Secondly, once the zip file download is complete, Extract the file so that you see the unzipped Selenium Java folder.
You can select any destination folder on your machine to save the extracted files. We have selected “E:\Softwares ” as seen in the below screenshot:
3. Thirdly, once the extraction is complete, open the downloaded Selenium folder.
4. Subsequently, the extracted folder contents would look like below:
- libs folder– It contains the jar files that support Selenium execution and provide
- Two jar files that are essentially the selenium jars to use Selenium WebDriver
- The CHANGELOG file includes the details of the version changes along with the features offered by each of them.
- The LICENSE and NOTICE files contain the license details and the notice corresponding to the Selenium bindings.
All these jars and the supporting files in the libs folder will be needed while we will be developing the automated test cases and will provide details about the same while configuring Selenium WebDriver in Eclipse.
Now that you have seen downloading the Selenium WebDriver for Windows operating system let us quickly understand how we can download the Selenium WebDriver client in macOS.
How to download Selenium WebDriver for Java on macOS?
Downloading Selenium WebDriver client on your macOS is very similar to that in windows. Below are the steps that you will need to follow:
1. Go to the official Selenium website and download the Selenium WebDriver Java Client. You can refer to the screenshot in the steps for Windows download above.
2. It will download the “zip ” file for the stable version of Selenium WebDriver, and double-clicking on the zip file will unzip all the files in the current folder. You will now see that the Selenium Java Client downloads successfully and is visible in your ‘Downloads ‘ folder.
3. Now, within this downloaded folder, you can see the ‘libs ‘ folder, two jar files & the changelog, which are same as it was for the Windows platform
And, this completes, our quick learning of downloading the Selenium WebDriver as per the platform or operating system you are using. As we know, Java, being the platform-independent programming language, the Selenium WebDriver bindings for the Java language provides the same files. It is irrespective of which platform/operating system you use for the development of automation test cases using Selenium WebDriver for Java.
- The process to download the Selenium WebDriver is almost same for all the platforms. Additionally, the Selenium portals automatically download the zip file corresponding to your platform.
- Moreover, the content of Selenium WebDriver for Java are almost the same on all platforms.
- In addition to the above, the Selenium 4 – Alpha version binding sare also available for download on the portal. Subsequently, we will be covering the details of Selenium 4 in the future article.