Selenium ChromeDriver issue - Want to run it in background but not as headless browser

0 votes
I am looking for a way to run selenium tests in the background with ChromeDriver. With the background I mean as in, not the foreground focussed window. I can actually do this, but as soon as actions like opening a new tab or switching between windows (so basically switching window handles) happen in ChromeDriver, the browser window gets pushed to the foreground.

So my question is, how can I prevent this from happening without running the test headless?

Any suggestions are appreciated, open for discussion
Mar 27, 2018 in Selenium by nitinrawat895
• 11,380 points
8,120 views

1 answer to this question.

0 votes
This is a flaw with ChromeDriver. Tried doing the same with Firefox, and it worked for me. If you still want to use ChromeDriver, use a VM or a remote computer and attach to the process remotely to do the debugging if needed.
answered Mar 27, 2018 by nsv999
• 5,500 points

@nsv999, can't we use Ctrl+Tab keyboard action to put the browser window in background? 

Related Questions In Selenium

0 votes
0 answers

How to configure ChromeDriver to initiate the browser in the Headless mode using Selenium?

I'm currently working on a Python script ...READ MORE

Apr 2, 2019 in Selenium by Surya
• 970 points
1,826 views
0 votes
1 answer

How to run Selenium test cases in Headless Chrome browser?

@Afreen to run selenium test cases in ...READ MORE

answered May 17, 2019 in Selenium by Kushal
4,170 views
0 votes
1 answer
+1 vote
2 answers

How to get page source as it is in browser using selenium.

I needed to wait for an element ...READ MORE

answered Apr 18, 2020 in Selenium by laiman
• 330 points
19,340 views
0 votes
2 answers

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,500 points
13,771 views
0 votes
2 answers

Problem while using InternetExplorerDriver in Selenium WebDriver

enable trusted connection  in internet explorer by ...READ MORE

answered Aug 31, 2020 in Selenium by Sri
• 3,190 points
9,187 views
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,910 points
7,263 views
0 votes
2 answers

How to use such xpath to find web elements

xpath are two types. 1) Absolute XPath:    /html/b ...READ MORE

answered Sep 3, 2020 in Selenium by Sri
• 3,190 points
7,901 views
0 votes
2 answers

Can anyone help me that how to run Selenium WebDriver test cases in Chrome?

You first need to download chrome driver ...READ MORE

answered Aug 26, 2019 in Selenium by Abha
• 28,140 points
2,012 views
0 votes
1 answer

Headless ChromeDriver using Python Selenium error: Fails To Start— “DevTools request failed”

This should be because your ChromeDriver is ...READ MORE

answered Mar 30, 2018 in Selenium by nsv999
• 5,500 points
2,096 views
webinar REGISTER FOR FREE WEBINAR X
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP