public override void Initialize(DriverOptions driverOptions) { // Do not set implicit waits. Prefer usage of explicit waits. // Can always turn on implicit waits at a later time, but once set, they cannot be changed. DefaultUrl = driverOptions.Url; var internetExplorerDriverService = InternetExplorerDriverService.CreateDefaultService(driverOptions.DriverExePath); var internetExplorerOptions = new InternetExplorerOptions(); internetExplorerOptions.IntroduceInstabilityByIgnoringProtectedModeSettings = true; internetExplorerOptions.AddAdditionalCapability("EnsureCleanSession", true); internetExplorerDriverService.Port = driverOptions.Port; // this is the port for the driver, not the webpage WebDriver = new InternetExplorerDriver(internetExplorerDriverService, internetExplorerOptions); }
public abstract void Initialize(DriverOptions driverOptions);