Is it possible for selenium to have all the browser tabs focused simultaneously?


My project needs to have about 5 or 6 active tabs in each browser instance, is it possible for selenium to have each tab of a browser focused at the same time so, for example, video autoplay can continue to work on all tabs simultaneously?

I’m aware of driver.switchTo().window(); but that will just change the focus to another tab while I need something that will keep all active tabs in focus.

>Solution :

No, Selenium can focus at only one tab at a time.

To switch focus to other tabs you would need to do window handling.

Leave a Reply Cancel reply