I've encountered a problem with specifying the capabilities driver should meet. I need a browser instance to have pop ups blocked. (must have)
Capabilities code:
DesiredCapabilities caps = DesiredCapabilities().firefox();
FirefoxProfile profile = new FirefoxProfile();
profile.setPreference("dom.popup_maximum", 0);
caps.setCapability(FirefoxDriver.PROFILE, profile);
The code for creating driver:
WebDriver driver1 = new FirefoxDriver(caps); // this one works
WebDriver driver2 = new RemoteWebDriver(properUrl, caps); // this one does not
By does work / does not work I mean, that driver1 has the pop ups blocked as it should and the driver2 allows pop ups when it should not.
The connection to grid hub is correct, because the driver does work, but unfortunately settings are not set the way they suppose to be.
Could anyone help me out please?