Microsoft Edge WebDriver implementation for Selenium WebDriver browser automation with EdgeOptions configuration and EdgeDriverService management.
npx @tessl/cli install tessl/maven-org-seleniumhq-selenium--selenium-edge-driver@4.33.0Selenium Edge Driver is a Microsoft Edge WebDriver implementation for Selenium WebDriver browser automation. It extends the ChromiumDriver base class and provides Edge-specific functionality including EdgeOptions for browser configuration, EdgeDriverService for managing the EdgeDriver executable, and full WebDriver API compatibility.
<dependency>
<groupId>org.seleniumhq.selenium</groupId>
<artifactId>selenium-edge-driver</artifactId>
<version>4.33.0</version>
</dependency>import org.openqa.selenium.edge.EdgeDriver;
import org.openqa.selenium.edge.EdgeOptions;
import org.openqa.selenium.edge.EdgeDriverService;import org.openqa.selenium.edge.EdgeDriver;
import org.openqa.selenium.edge.EdgeOptions;
// Basic usage with default options
EdgeDriver driver = new EdgeDriver();
// With custom options
EdgeOptions options = new EdgeOptions();
options.addArguments("--headless");
options.addArguments("--disable-gpu");
EdgeDriver driver = new EdgeDriver(options);
// Navigate and interact
driver.get("https://example.com");
String title = driver.getTitle();
driver.quit();Selenium Edge Driver is built around several key components:
Core WebDriver implementation providing full browser automation capabilities for Microsoft Edge. Supports both regular Edge browser and WebView2 applications.
public class EdgeDriver extends ChromiumDriver {
public EdgeDriver();
public EdgeDriver(EdgeOptions options);
public EdgeDriver(EdgeDriverService service);
public EdgeDriver(EdgeDriverService service, EdgeOptions options);
public EdgeDriver(EdgeDriverService service, EdgeOptions options, ClientConfig clientConfig);
@Beta
public static RemoteWebDriverBuilder builder();
}Configuration and capability management for EdgeDriver with Edge-specific options and WebView2 support.
public class EdgeOptions extends ChromiumOptions<EdgeOptions> {
public static final String CAPABILITY = "ms:edgeOptions";
public static final String LOGGING_PREFS = "ms:loggingPrefs";
public static final String WEBVIEW2_BROWSER_NAME = "webview2";
public EdgeOptions();
public EdgeOptions useWebView(boolean enable);
public EdgeOptions merge(Capabilities extraCapabilities);
}Lifecycle management for the EdgeDriver executable with extensive configuration options for logging, networking, and operational behavior.
public class EdgeDriverService extends DriverService {
public static final String EDGE_DRIVER_NAME = "msedgedriver";
public static final String EDGE_DRIVER_EXE_PROPERTY = "webdriver.edge.driver";
public EdgeDriverService(File executable, int port, Duration timeout, List<String> args, Map<String, String> environment);
public String getDriverName();
public String getDriverProperty();
public Capabilities getDefaultDriverOptions();
public static EdgeDriverService createDefaultService();
public static class Builder extends DriverService.Builder<EdgeDriverService, Builder> {
public Builder withAppendLog(boolean appendLog);
public Builder withBuildCheckDisabled(boolean noBuildCheck);
public Builder withLoglevel(ChromiumDriverLogLevel logLevel);
public Builder withSilent(boolean silent);
public Builder withVerbose(boolean verbose);
public Builder withAllowedListIps(String allowedListIps);
public Builder withReadableTimestamp(Boolean readableTimestamp);
}
}Metadata provider and factory for EdgeDriver instances with capability matching and WebDriver integration.
public class EdgeDriverInfo extends ChromiumDriverInfo {
public String getDisplayName();
public Capabilities getCanonicalCapabilities();
public boolean isSupporting(Capabilities capabilities);
public boolean isSupportingCdp();
public boolean isSupportingBiDi();
public boolean isAvailable();
public boolean isPresent();
public Optional<WebDriver> createDriver(Capabilities capabilities);
}EdgeOptions options = new EdgeOptions();
options.useWebView(true);
EdgeDriver driver = new EdgeDriver(options);EdgeDriverService service = new EdgeDriverService.Builder()
.withVerbose(true)
.withLogFile(new File("edge-driver.log"))
.withAllowedListIps("127.0.0.1")
.build();
EdgeDriver driver = new EdgeDriver(service);EdgeOptions options = new EdgeOptions();
RemoteWebDriver driver = EdgeDriver.builder()
.oneOf(options)
.address("http://localhost:4444")
.build();