Internet Explorer WebDriver implementation for Selenium providing automated browser control specifically for IE browsers through the Selenium WebDriver API.
—
Pending
Does it follow best practices?
Impact
Pending
No eval scenarios have been run
Pending
The risk profile of this skill
The Selenium Internet Explorer Driver provides automated browser control capabilities specifically for Internet Explorer browsers through the Selenium WebDriver API. It implements the W3C WebDriver specification and offers a comprehensive Java API for controlling IE browser instances, including capabilities for navigation, element interaction, window management, and browser-specific configuration options.
org.seleniumhq.selenium:selenium-ie-driver:4.33.0pom.xml:<dependency>
<groupId>org.seleniumhq.selenium</groupId>
<artifactId>selenium-ie-driver</artifactId>
<version>4.33.0</version>
</dependency>import org.openqa.selenium.ie.InternetExplorerDriver;
import org.openqa.selenium.ie.InternetExplorerOptions;
import org.openqa.selenium.ie.InternetExplorerDriverService;import org.openqa.selenium.ie.InternetExplorerDriver;
import org.openqa.selenium.ie.InternetExplorerOptions;
import org.openqa.selenium.ie.InternetExplorerDriverService;
import org.openqa.selenium.WebDriver;
import org.openqa.selenium.By;
import org.openqa.selenium.WebElement;
// Basic IE driver with default settings
WebDriver driver = new InternetExplorerDriver();
// IE driver with custom options for better reliability
InternetExplorerOptions options = new InternetExplorerOptions()
.ignoreZoomSettings() // Ignore zoom level for consistent element location
.requireWindowFocus() // Ensure window has focus for interaction
.enablePersistentHovering() // Improve hover behavior
.withInitialBrowserUrl("about:blank"); // Set initial URL
WebDriver driver = new InternetExplorerDriver(options);
try {
// Navigate to a website
driver.get("https://example.com");
// Find and interact with elements
WebElement searchBox = driver.findElement(By.name("q"));
searchBox.sendKeys("Selenium WebDriver");
WebElement submitButton = driver.findElement(By.xpath("//input[@type='submit']"));
submitButton.click();
// Wait and verify results
Thread.sleep(2000);
System.out.println("Page title: " + driver.getTitle());
} finally {
// Always clean up resources
driver.quit();
}The Selenium IE Driver is built around several key components:
Core WebDriver functionality for creating and managing Internet Explorer browser instances. Provides the main entry point for IE automation.
public class InternetExplorerDriver extends RemoteWebDriver {
public InternetExplorerDriver();
public InternetExplorerDriver(InternetExplorerOptions options);
public InternetExplorerDriver(InternetExplorerDriverService service);
public InternetExplorerDriver(
InternetExplorerDriverService service,
InternetExplorerOptions options
);
public InternetExplorerDriver(
InternetExplorerDriverService service,
InternetExplorerOptions options,
ClientConfig clientConfig
);
public static RemoteWebDriverBuilder builder(); // @Beta
}Comprehensive configuration system for IE-specific browser settings and behaviors. Supports fluent API pattern for easy configuration chaining.
public class InternetExplorerOptions extends AbstractDriverOptions<InternetExplorerOptions> {
public InternetExplorerOptions();
public InternetExplorerOptions(Capabilities source);
public InternetExplorerOptions merge(Capabilities extraCapabilities);
public InternetExplorerOptions ignoreZoomSettings();
public InternetExplorerOptions requireWindowFocus();
public InternetExplorerOptions enablePersistentHovering();
public InternetExplorerOptions withInitialBrowserUrl(String url);
public InternetExplorerOptions elementScrollTo(ElementScrollBehavior behavior);
}Service lifecycle management for the IEDriverServer executable, including process creation, configuration, and cleanup.
public class InternetExplorerDriverService extends DriverService {
public static InternetExplorerDriverService createDefaultService();
public static class Builder extends DriverService.Builder<
InternetExplorerDriverService,
InternetExplorerDriverService.Builder
> {
public Builder withLogLevel(InternetExplorerDriverLogLevel logLevel);
public Builder withHost(String host);
public Builder withExtractPath(File extractPath);
public Builder withSilent(Boolean silent);
}
}// Log level enumeration
public enum InternetExplorerDriverLogLevel {
TRACE, DEBUG, INFO, WARN, ERROR, FATAL
}
// Element scroll behavior options
public enum ElementScrollBehavior {
TOP(0), BOTTOM(1);
public int getValue();
public static ElementScrollBehavior fromString(String text);
}
// Driver metadata and factory
public class InternetExplorerDriverInfo implements WebDriverInfo {
public String getDisplayName();
public Capabilities getCanonicalCapabilities();
public boolean isSupporting(Capabilities capabilities);
public boolean isSupportingCdp();
public boolean isSupportingBiDi();
public boolean isAvailable();
public boolean isPresent();
public int getMaximumSimultaneousSessions();
public Optional<WebDriver> createDriver(Capabilities capabilities);
}The IE driver throws specific exceptions for common error conditions:
Internet Explorer has specific security requirements that may affect automation:
introduceFlakinessByIgnoringSecurityDomains() option (not recommended)