Saturday, November 23, 2019

Selenium4: Working with two parallel windows in Selenium Automation

A new method newWindow() is introduced in Selenium 4 (Alpha). Using this method we can open a new tab or new window from the current window. We can switch between the TABS/WINDOWS and work in parallel.

newWindow(WindowType.TAB) -- Opens a new tab

newWindow(WindowType.WINDOW) -- Opens a new window

In this post we will see working with two windows in parallel.

1. The first window launches the https://www.selenium.dev and prints the title
2. Open the new window/tab, switch to it and launch http://www.google.com
3. Search for "qababu.com" in Google
4. Switch back to first window and click on the projects menu on

Above one is our test scenario, checkout the below video


Thanks for reading and watching. #HappyLearning #HappyTesting #qababu

No comments:

Post a Comment

Selenium4: Working with two parallel windows in Selenium Automation

A new method newWindow() is introduced in Selenium 4 (Alpha). Using this method we can open a new tab or new window from the current window...