webdriverio: Cannot configure MicrosoftEdge with webdriverio v5+
Environment (please complete the following information):
- WebdriverIO version: 5.0.3
- Mode: WDIO Testrunner
- If WDIO Testrunner, running sync/async: sync
- Node.js version: 11.6.0
- NPM version: 6.5.0
- Browser name and version: MicrosoftEdge v44.17763.1.0
- Platform name and version: Windows 10 v1809
- Additional wdio packages used (if applicable): @wdio/selenium-standalone service
Config of WebdriverIO
capabilities: {
{
maxInstances: 1,
browserName: 'MicrosoftEdge',
platformName: 'windows 10'
}
}
Describe the bug
I am migrating a v4 configuration that works with:
capabilities: {
{
maxInstances: 1,
browserName: 'MicrosoftEdge',
osPlatform: 'Windows',
osVersion: '10'
}
}
but if I use this configuration with webdriverio v5, I get:
[0-1] 2018-12-28T11:45:31.086Z WARN webdriver: Request failed due to Illegal key values seen in w3c capabilities: [osPlatform, osVersion]
[0-1] 2018-12-28T11:45:31.091Z WARN webdriver: Request failed due to Illegal key values seen in w3c capabilities: [osPlatform, osVersion]
[0-1] 2018-12-28T11:45:31.095Z WARN webdriver: Request failed due to Illegal key values seen in w3c capabilities: [osPlatform, osVersion]
[0-1] 2018-12-28T11:45:31.099Z ERROR webdriver: Request failed due to Error: Illegal key values seen in w3c capabilities: [osPlatform, osVersion]
at Request._callback (.\node_modules\webdriver\src\request.js:86:27)
at Request.self.callback (.\node_modules\request\request.js:185:22)
at Request.emit (events.js:188:13)
at Request.EventEmitter.emit (domain.js:441:20)
at Request.<anonymous> (.\node_modules\request\request.js:1161:10)
at Request.emit (events.js:188:13)
at Request.EventEmitter.emit (domain.js:441:20)
at IncomingMessage.<anonymous> (.\node_modules\request\request.js:1083:12)
at Object.onceWrapper (events.js:276:13)
at IncomingMessage.emit (events.js:193:15)
[0-1] 2018-12-28T11:45:31.104Z ERROR wdio-runner: Error: Illegal key values seen in w3c capabilities: [osPlatform, osVersion]
at Request._callback (.\node_modules\webdriver\src\request.js:86:27)
at Request.self.callback (.\node_modules\request\request.js:185:22)
at Request.emit (events.js:188:13)
at Request.EventEmitter.emit (domain.js:441:20)
at Request.<anonymous> (.\node_modules\request\request.js:1161:10)
at Request.emit (events.js:188:13)
at Request.EventEmitter.emit (domain.js:441:20)
at IncomingMessage.<anonymous> (.\node_modules\request\request.js:1083:12)
at Object.onceWrapper (events.js:276:13)
at IncomingMessage.emit (events.js:193:15)
So I have tried:
capabilities: {
{
maxInstances: 1,
browserName: 'MicrosoftEdge'
}
}
which triggers:
Error: Unable to create session from {
"desiredCapabilities": {
"browserName": "MicrosoftEdge"
},
"capabilities": {
"firstMatch": [
{
"browserName": "MicrosoftEdge"
}
]
}
}
Build info: version: '3.141.0', revision: '2ecb7d9a', time: '2018-10-31T20:22:52'
System info: host: 'DESK', ip: '192.168.75.1', os.name: 'Windows 10', os.arch: 'amd64', os.version: '10.0', java.version: '1.8.0_131'
Driver info: driver.version: unknown
at Request._callback (.\node_modules\webdriver\src\request.js:86:27)
at Request.self.callback (.\node_modules\request\request.js:185:22)
at Request.emit (events.js:188:13)
at Request.EventEmitter.emit (domain.js:441:20)
at Request.<anonymous> (.\node_modules\request\request.js:1161:10)
at Request.emit (events.js:188:13)
at Request.EventEmitter.emit (domain.js:441:20)
at IncomingMessage.<anonymous> (.\node_modules\request\request.js:1083:12)
at Object.onceWrapper (events.js:276:13)
at IncomingMessage.emit (events.js:193:15)
and
capabilities: {
{
maxInstances: 1,
browserName: 'MicrosoftEdge',
platformName: 'windows 10'
}
}
which triggers:
Error: Unable to create session from {
"desiredCapabilities": {
"platformName": "windows 10",
"browserName": "MicrosoftEdge"
},
"capabilities": {
"firstMatch": [
{
"browserName": "MicrosoftEdge",
"platformName": "windows 10"
}
]
}
}
Build info: version: '3.141.0', revision: '2ecb7d9a', time: '2018-10-31T20:22:52'
System info: host: 'DESK', ip: '192.168.75.1', os.name: 'Windows 10', os.arch: 'amd64', os.version: '10.0', java.version: '1.8.0_131'
Driver info: driver.version: unknown
at Request._callback (.\node_modules\webdriver\src\request.js:86:27)
at Request.self.callback (.\node_modules\request\request.js:185:22)
at Request.emit (events.js:188:13)
at Request.EventEmitter.emit (domain.js:441:20)
at Request.<anonymous> (.\node_modules\request\request.js:1161:10)
at Request.emit (events.js:188:13)
at Request.EventEmitter.emit (domain.js:441:20)
at IncomingMessage.<anonymous> (.\node_modules\request\request.js:1083:12)
at Object.onceWrapper (events.js:276:13)
at IncomingMessage.emit (events.js:193:15)
In the last two cases, Microsoft Edge is launched but is not automated.
Expected behaviour
Any capabilities configuration that works.
Note that I had no issue configuring chrome, firefox and internet explorer with v5 as the capabilities did not require any change since v4.
About this issue
- Original URL
- State: closed
- Created 6 years ago
- Comments: 21 (8 by maintainers)
@mgrybyk could you post some guide on how to enable wdio working with windows 10 and edge please? I think I’ve looked through the whole Google already
@christian-bromann,
I am progressing with this issue and I am keeping you updated because you might want to document this (
@wdio/selenium-standalone-service).selenium-standalone installinstalls and uses an obsolete version of MicrosoftEdgeDriiver located at./node_modules/selenium-standalone/.selenium/edgedriver/17134-MicrosoftEdgeDriver.exe.This version is designed for MS Edge 17.17134 and is capable of opening and closing MS Edge 18.17763 (latest) but won’t send any command. This is what I have experienced.
In fact Microsoft has recently changed the way to install MicrosoftWebDriver.exe. See https://blogs.windows.com/msedgedev/2018/06/14/webdriver-w3c-recommendation-feature-on-demand/
You now need to install it from Settings -> Manage Optional Features:
or use
DISM.exe /Online /Add-Capability /CapabilityName:Microsoft.WebDriver~~~~0.0.1.0as mentionned on the Microosft WebDriver page at https://developer.microsoft.com/en-us/microsoft-edge/tools/webdriver/#downloadsThen you need to add seleniumArgs in wdio.conf.js as shown below:
I have raised an issue with selenium-standalone at https://github.com/vvo/selenium-standalone/issues/419.
The tests are now executing but all tests fail for the same reason, which pertains to webdriverio’s browser.waitUntil:
Please note that nodejs version is 11.6.0 so Promise is available on the server and client code runs with the @babel/polyfill so Promise is also available in the browser.
Please note that the same tests work in Chrome, Firefox and Internet Explorer after being migrated from webdriverio v4 to webdriverio v5, so the issue is not the tests,
Thank you for your help.