SELENIUM INSTALLATION



SELENIUM INSTALLATION
Selenium setup is quite different from the setup of other commercial tools. You don’t install a tool using Selenium binaries but rather set up your test automation project to use such binaries in the language of your choice. The Selenium binary you would need depends on the browsers you want to run your tests upon.

USING BROWSER SPECIFIC JAR

If you want to run tests only in a specific browser, you can add the dependency for that browser in your pom.xml file. For example, you should add following dependency in your pom.xml file to run your tests only in Firefox:
<dependency> <groupId>org.seleniumhq.selenium</groupId> <artifactId>selenium-firefox-driver</artifactId> <version>3.X</version> </dependency>
In a similar manner, if you want to run tests only in Chrome, you should add the following dependency:
<dependency> <groupId>org.seleniumhq.selenium</groupId> <artifactId>selenium-chrome-driver</artifactId> <version>3.X</version> </dependency>

USING NON BROWSER SPECIFIC JAR

More often than not you would need to run tests on more than one browser. Hence you would use selenium-java Maven dependency in your project. The selenium-java JAR contains the language bindings and the drivers but not the server side piece.
<dependency> <groupId>org.seleniumhq.selenium</groupId> <artifactId>selenium-java</artifactId> <version>3.X</version> </dependency>

USING STANDALONE JAR

If you plan to use Selenium Grid then you should download selenium-server-standalone JAR file. Selenium-server-standalone jar is never uploaded, but all the components are available via selenium-server. The standalone JAR contains everything, including the remote Selenium server and the client-side bindings. This means that if you use the selenium-server-standalone jar in your project, then you don't have to add selenium-java or a browser specific jar.

3 comments:

Featured Post

How to control Chromedriver using curl

How to control Chromedriver using curl Here is how to use Chromedriver without libraries like  selenium-webdriver . This can be useful ...