Dynamically installs the latest Selenium browser driver and set its system property. Supported browser driver:-
- Chrome -
webdriver.chrome.driver
system property will be set to the installed driver path.
<dependency>
<groupId>com.github.choonchernlim</groupId>
<artifactId>selenium-driver-installer</artifactId>
<version>0.1.0</version>
</dependency>
class ServiceNowChangeRequestSeleniumClient {
static void main(String[] args) {
// Add this line... and that's it.
SeleniumDriverInstaller.chrome()
final WebDriver driver = new ChromeDriver()
...
}
}