11/25/17

How To Launch Edge Browser Using Microsoft WebDriver


Download Microsoft WebDriver from here to launch Edge Browser. Download the proper version of the driver based on your OS build number. If the extension of the downloaded file is “.msi“, you need to install it to get the “.exe” driver.
import org.openqa.selenium.WebDriver;
import org.openqa.selenium.edge.EdgeDriver;

public class GeckoDriver {

public static void main(String[] args) {
System.setProperty("webdriver.edge.driver", "C://Drivers//MicrosoftWebDriver.exe");
WebDriver driver = new EdgeDriver();
driver.navigate.to("http://www.pavantestingtools.com");
driver.close();
}
}

0 comments:

Post a Comment

Google Q&A Forum