I have recently updated my selenium libraries from 2.46.0 to 2.53.0 (the most recent) in order to run tests on a Windows 10 machine with the Edge browser.
I have added this to my tests' setup phase to initialize the webdriver as an EdgeDriver:
System.setProperty("webdriver.edge.driver", driverDir+"MicrosoftWebDriver.exe"); DesiredCapabilities capabilities = new DesiredCapabilities("MicrosoftEdge", "", Platform.WINDOWS); driver = new EdgeDriver(capabilities);
the "driver" field being an object of the WebDriver class.
This successfully starts the Edge browser but, the url that I attempt to get never gets used.
I have tried both drivers that Microsoft has to offer for this browser found here
Here is the "About this app" section of the settings to show the version:
I can successfully load the page manually using the browser that was launched automatically.
Letting the test cases fail on hudson, I was given this stack trace in the console window:
15:13:04 [junit] Unknown error (WARNING: The server did not provide any stacktrace information) 15:13:04 [junit] Command duration or timeout: 100.28 seconds 15:13:04 [junit] Build info: version: '2.53.0', revision: '35ae25b', time: '2016-03-15 16:57:40' 15:13:04 [junit] System info: host: 'DESKTOP-7LLLD31', ip: '172.16.4.159', os.name: 'Windows 8', os.arch: 'amd64', os.version: '6.2', java.version: '1.7.0_51' 15:13:04 [junit] Driver info: org.openqa.selenium.edge.EdgeDriver 15:13:04 [junit] org.openqa.selenium.WebDriverException: Unknown error (WARNING: The server did not provide any stacktrace information) 15:13:04 [junit] Command duration or timeout: 100.28 seconds 15:13:04 [junit] Build info: version: '2.53.0', revision: '35ae25b', time: '2016-03-15 16:57:40' 15:13:04 [junit] System info: host: 'DESKTOP-7LLLD31', ip: '172.16.4.159', os.name: 'Windows 8', os.arch: 'amd64', os.version: '6.2', java.version: '1.7.0_51' 15:13:04 [junit] Driver info: org.openqa.selenium.edge.EdgeDriver 15:13:04 [junit] at java.lang.reflect.Constructor.newInstance(Constructor.java:526) 15:13:04 [junit] at org.openqa.selenium.remote.ErrorHandler.createThrowable(ErrorHandler.java:206) 15:13:04 [junit] at org.openqa.selenium.remote.ErrorHandler.throwIfResponseFailed(ErrorHandler.java:158) 15:13:04 [junit] at org.openqa.selenium.remote.RemoteWebDriver.execute(RemoteWebDriver.java:678) 15:13:04 [junit] at org.openqa.selenium.remote.RemoteWebDriver.startSession(RemoteWebDriver.java:249) 15:13:04 [junit] at org.openqa.selenium.remote.RemoteWebDriver.(RemoteWebDriver.java:131) 15:13:04 [junit] at org.openqa.selenium.remote.RemoteWebDriver.(RemoteWebDriver.java:144) 15:13:04 [junit] at org.openqa.selenium.edge.EdgeDriver.(EdgeDriver.java:152) 15:13:04 [junit] at org.openqa.selenium.edge.EdgeDriver.(EdgeDriver.java:120)
I am not sure what is going on here, anything will help, thanks.