hjsblogger / selenium-manager-demo

This simple repo shows how to use Selenium Manager (in Selenium 4.7) with Java

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

This simple example demonstrates how to use Selenium Manager in Selenium 4.6 (and above). For the demonstration, I have made use of Selenium 4.7.

What is Selenium Manager

Selenium Manager is a new tool that helps to get a working environment to run Selenium out of the box.

Available with Selenium v4.6 (and above), it automatically configures the browser drivers for Chrome, Firefox, Internet Explorer, and Edge.

More information about Selenium Manager is available in the following locations:

How to use Selenium Manager in Java

Selenium-Manager-POM

Selenium-Java-POM

Execution

Here is all what is needed to instantiate the browsers:

  • Chrome ------> WebDriver driver = new ChromeDriver();
  • Firefox ------> WebDriver driver = new FirefoxDriver();
  • Edge --------> WebDriver driver = new EdgeDriver();

For demonstration, I used the getInstance method in SeleniumManager to print the location where the respective browser drivers are downloaded:

VS_IDE_Selenium_Manager_2

On execution, the browser drivers are downloaded in /Users/applemacbook_pro/.cache/selenium folder. These would be re-downloaded in case there is any update in the browser version.

CMD_Selenium_Manager

Have Feedback?

Feel free to fork the repo and contribute to make it better! Email to himanshu[dot]sheth[at]gmail[dot]com for any queries or ping me on the following social media sites:

Twitter: @hjsblogger
LinkedIn: @hjsblogger

About

This simple repo shows how to use Selenium Manager (in Selenium 4.7) with Java

License:MIT License


Languages

Language:Java 100.0%