Am working on a banking application. Our requirement is to execute tests in parallel in one system.

A) Below is how our application responds to selenium parallel execution :-

  • Does not allow multiple logins in IE

  • Allows multiple logins in chrome and FF [During automation we create new profile every time, so I presume that selenium creates new browser profile every time ]

We are able to execute tests in parallel using firefox and chrome without any session issues.But while executing on IE our application logs out from the second instance automatically.. I have tried launching IE in private mode using below IE capabilities , But still facing problem in IE

DesiredCapabilities capabilities = DesiredCapabilities.internetExplorer();  
    capabilities.setCapability(InternetExplorerDriver.FORCE_CREATE_PROCESS, true);  
    сapabilities.setCapability(InternetExplorerDriver.IE_SWITCHES, "-private");
    InternetExplorerDriver driver = new InternetExplorerDriver(capabilities); 

Manually if you launch two IE in private mode with two different logins, it is working fine, Am getting issue only when automating via selenium.

We are using our inhouse framework for running multiple instance. we are not using testng or other unit testing frameworks

Could you please help me over come this IE session issue?

Please let me know if you need more details..

Thanks in advance..


Below link says lot about how to design application not to share sessions between tabs...But I did not found any solution for my issue..


  • 2
    fyi in other browsers subsequent incognite/private windows still share cookies with the first incognito window. Many folks don't realize this. It probably has to be this was so that pop-ups and page transitions still work correctly. u may start incognito but if you use a system with a login, it will need to remember you, even in the incognito session. The assurance is that it is not a different session and can only be one. Jan 27, 2017 at 14:54

4 Answers 4


If I remember correctly, IE shares cookies even in in-private mode.

Caveat: Mac user currently, and I have not touched IE for some time. You might want to check that with this site.


Maybe this will help

DesiredCapabilities capabilities = DesiredCapabilities.internetExplorer();
capabilities.setCapability(InternetExplorerDriver.IE_ENSURE_CLEAN_SESSION, true);
InternetExplorerDriver driver = new InternetExplorerDriver(capabilities); 
  • 1
    How does this help? Feb 9, 2017 at 2:49
  • Thanks Frederik, I have tried all straight forward solutions :) Is there any hack we can do?
    – TechDog
    Feb 9, 2017 at 6:33

Try using something like this (it's Ruby code but presumably you can adapt to your Java language):

before(:each) do
  caps = Selenium::WebDriver::Remote::Capabilities..internet_explorer('ie.ensureCleanSession' => true, 'ie.browserCommandLineSwitches' => 'private')
  @driver = Selenium::WebDriver.for(:internet_explorer, :desired_capabilities => caps)
  @base_url = "https://www.example.com/"
  @accept_next_alert = true
  @driver.manage.timeouts.implicit_wait = 30
  • Thank you Michael Durrant, I have tried this, But still facing the issue....
    – TechDog
    Dec 28, 2016 at 13:46

You will need to have multiple IE nodes in your selenium grid if you want to do this , its because IE is so tightly bound to the OS.

you can download free vm images for browser testing from here https://developer.microsoft.com/en-us/microsoft-edge/tools/vms/

then spin them up with your chosen vm host and add them to the grid then your tests can run in parallel.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.