Search code examples
seleniumsafariselenium-webdriverbrowserstack

How can I disable Pop-up Blocker in Safari using Selenium Remote Webdriver?


I'm using BrowserStack's Selenium Hub and trying to test an application that requires the pop up blocker to be turned off. Anyone know how to do this from the web driver or have any good workaround ideas?

When the VM starts on BrowserStack's end, its always turned on and I need to turn the pop-up blocker off. They do not provide access to anything other than the browser so I can't issue command line calls.

I have a solution for IE and Chrome but need a solution for Safari.


Solution

  • You can disable pop-up by passing this capability

    javascriptEnabled='false'
    

    similar to

    device='ios'