selenium-ide
selenium-ide copied to clipboard
Not able to run tests with selenium-side-runner on Edge
🐛 Bug Report
Preconditons:
Edge driver is installed. Path to edge driver is defined.
Steps to reproduce the behavior:
- Run command: selenium-side-runner -c "browserName=edge" suit_name.side
Result is:
Test suite failed to run
Do not know how to build driver: edge; did you forget to call usingServer(url)?
at Builder.build (../AppData/Roaming/npm/node_modules/selenium-side-runner/node_modules/selenium-webdriver/index.js:692:15)
at buildDriver (../AppData/Roaming/npm/node_modules/selenium-side-runner/node_modules/jest-environment-selenium/dist/index.js:66:17)
at WebdriverEnvironment.setup (../AppData/Roaming/npm/node_modules/selenium-side-runner/node_modules/jest-environment-selenium/dist/index.js:37:32)
I've tried also to run selenium server locally and point it in the command: selenium-side-runner -c "browserName=edge" -s 0.0.0.0:4444 suit_name.side Result that I received for that was: ` ● Test suite failed to run
TypeError: Cannot read property 'endsWith' of null
at HttpClient.send (../AppData/Roaming/npm/node_modules/selenium-side-runner/node_modules/selenium-webdriver/http/index.js:121:14)
at Executor.execute (../AppData/Roaming/npm/node_modules/selenium-side-runner/node_modules/selenium-webdriver/lib/http.js:482:33)`
Expected behavior
Test suite will be running, same as for other browser drivers (like for Chrome).
Environment
OS: Windows 10 Pro Selenium IDE Version: 3.12.3 Selenium SIDE Runner Version: 3.12.1 Node version: 10.13.0 Browser: Microsoft Edge Browser Version: 44.18362.1.0 (64-bit)
I wonder if we can get around to getting a windows CI going to test edge, atm I'll have to set up a vm and manually check it out.
I'm observing similar behavior trying to get Edge (Chromium) working with the webdrivers found here: https://developer.microsoft.com/en-us/microsoft-edge/tools/webdriver/
Maybe we should add an "Edge Chromium" option for this as a browser name?
In my case, I was using browser version: 80.0.361.9 (Official build) dev (64-bit)
I was noticing a similar message to the Edge message posted above.
I'm having the same issue with Edge.
I've managed to get around it by running the Edge webdriver on its own and pointing to it in the command.
So, with the webdriver listening on http://localhost:17556/ the command is selenium-side-runner -c "browserName=edge" -s http://localhost:17556/ suit_name.side
I have been having the same issue with this. I found if I update my browser name to MicrosoftEdge, it doesn't give this error: Do not know how to build driver: edge; did you forget to call usingServer(url)?
However, it gives this error instead: The MicrosoftWebDriver.exe could not be found on the current PATH. Please download the latest version of the MicrosoftEdgeDriver from https://www.microsoft.com/en-us/download/details.aspx?id=48212 and ensure it can be found on your PATH.
I've searched and searched, but have not found a solution for this. I have edgdriver and msedgedriver installed. Renamed msedgedriver to MicrosoftWebDriver, all return the same error. Is Edge compatible with v3 side runner? I've tried switching to v4, but that hasn't worked for me at all in Windows 10.
@clfordhub - Have you tried opening two pshell tabs and running the edgedriver in one tab and using the command in the comment above?
Hey, @toddtarsi I'm not able to run edgedriver, but I can successfully start msedgedriver. It's not looking for it in the path I expected, but I copied the files to the path it showed, and then it did start. I tried my side file again, but it was still asking for MicrosoftWebDriver.exe. What is displayed in my folder path is msedgedriver, so not quite sure what it's looking for or why it's not looking in the path I have specified in PS.
side note (I'm attempting this on v3 using node v14, but v4 and node v16 return the same) Something wrong with the path or naming still, just not sure what.
@clfordhub - Shoot, I was hoping if msedgedriver or edgedriver was running in a separate tab, it wouldn't have to worry about finding it on the path at all and just go right into building / running because some like ping style thing comes back or something. Dang! Well, sorry to be unable to help more with this. It might be worth it to use v3 or v4 of the selenium-webdriver directly and work backwards from that:
https://www.npmjs.com/package/selenium-webdriver
I think the IDE is obfuscating your problems down here, and if you can figure out how to get started here, you'll probably be able to bring what you learn back up into either version of the side-runner.
@clfordhub - To give some context, the error you're getting is coming back from this package, which are the JS bindings for the webdriver protocol. It's coming from when we build your driver using the "Builder API"
@clfordhub - Also also last response, if you can get to being stuck on just selenium-webdriver, and you reach out in the main selenium channel on Slack, you'll get help from some people who are way more capable than I am, which is another good reason to go that way.
Thanks! @toddtarsi It's very specific to MS Edge. FireFox and Chrome work fine in side runner and IDE. Edge IDE works fine too in IDE. It's just side runner that isn't cooperating with Edge. I used npm install to get edgedriver and msedgedriver, and let it do it's thing. I'll check Slack too.
Great thanks to the WA comment of Wolvester on 13 Mar 2020. For my case, I had to specify browserName as MicrosoftEdge instead of edge, hence I typed my command in following manner.
selenium-side-runner -c "browserName=MicrosoftEdge" -s http://localhost:17556 suit_name.side
Note) you can simply start up your msedgedriver.exe by just double clicking it. Then the console starts up and it gives you the driver version and listening port number.
My Edge version: 105.0.1343.33 My msedgedriver.exe version: 105.0.1343.33
Thanks, @doikota. In addition to typing the browser as "MicrosoftEdge", in order to get mine to work, I also had to change this:
Change the code on: ../../../../../node_modules_for_selenium/node_modules/selenium-side-runner/node_modules/selenium-webdriver/edge.js Line 85 const EDGEDRIVER_EXE = 'MicrosoftWevDriver.exe'; to const EDGEDRIVER_EXE = 'msedgedriver.exe';