Can we use Selenium to work with an already open browser session?

0 votes
Do you'll know if WebDriver can perform testing using a browser instance that's already running instead of a new one?
Apr 24, 2018 in Selenium by kappa3010
• 2,020 points
7,877 views

1 answer to this question.

0 votes

Yup its possible. Instead of a new instance, you can use the existing instance's sessionID to perform the test on the same instacne. Its done by using this:

webdriver.WebDriver.attachToSession(executor, session_id);

More details about the documentation here: https://seleniumhq.github.io/selenium/docs/api/javascript/module/selenium-webdriver/lib/webdriver_exports_WebDriver.html#WebDriver.attachToSession

answered Apr 24, 2018 by king_kenny
• 3,650 points
this page link is not working its blank
The page link is working fine.

Related Questions In Selenium

0 votes
1 answer

Can Selenium webdriver attach to already open browser window?

Nope, it can't be done. It's one ...READ MORE

answered Sep 25, 2018 in Selenium by Meci Matt
• 9,420 points
1,906 views
0 votes
1 answer

How can we use Selenium with Python?

First  Install Python based on the Operating ...READ MORE

answered May 7, 2018 in Selenium by Meci Matt
• 9,420 points
74 views
0 votes
1 answer

How to open a browser window in full screen using Selenium WebDriver with C#

Simply Use this: driver.Manage().Window.Maximize(); READ MORE

answered Jun 7, 2018 in Selenium by Samarpit
• 5,130 points
4,189 views
0 votes
1 answer

How can I use HTML Unit Driver as a headless browser with Selenium?

Hello @Nishant, follow these steps to use ...READ MORE

answered May 17 in Selenium by Anvi
• 13,960 points
277 views
0 votes
1 answer

Finding WebDriver element with Class Name in java

The better way to handle this element ...READ MORE

answered Apr 10, 2018 in Selenium by nsv999
• 5,110 points
976 views
0 votes
1 answer
0 votes
1 answer

Geo-location microphone camera pop up

To Allow or Block the notification, access using Selenium and you have to ...READ MORE

answered May 11, 2018 in Selenium by Samarpit
• 5,130 points
1,131 views
0 votes
1 answer

How to use such xpath to find web elements

It's much simpler to use: #MyDiv123 > div.super or ...READ MORE

answered Jun 14, 2018 in Selenium by Samarpit
• 5,130 points
873 views
0 votes
1 answer

Need to scroll down for locating an Element with Selenium

There are a couple of options for ...READ MORE

answered Apr 20, 2018 in Selenium by king_kenny
• 3,650 points
1,129 views
+4 votes
2 answers

Can we get the HTTP Response Code in Selenium with Java?

It is indeed possible to get http ...READ MORE

answered Apr 20, 2018 in Selenium by king_kenny
• 3,650 points
14,273 views