Running Selenium WebDriver without using EXE files
In order to run Selenium WebDriver on Chrome, Firefox, IE etc browser we need to set exe binary file path like below before initiate drivers. System.setProperty("webdriver.chrome.driver", "/absolutepathtobinarychromedriver"); System.setProperty("webdriver.gecko.driver", "/absolutepathtobinarygeckodriver"); If you forgot to set path to the driver executable file using System.setProperty then illegal state exception will occur. To avoid this we can use WebDriverManager in Maven project, you need to add the following dependency in your pom.xml file. <dependency> <groupId>io.github.bonigarcia</groupId> <artifactId>webdrivermanager</artifactId> <version>3.0.0</version> <scope>test</scope> </dependency> and in Gradle project dependencies { testCompile("io.github.bonigarcia:webdrivermanager:3.0.0") } WebDriverManager resolves the driver ...