So we got edge to work on Ubuntu and connect it to a selenium hub 4 (on the official hub 4 docker image) and everything's all fine there.
Now when it comes to the actual code of the C# tests, things are weird. First off, there are 2 packages for the Edge driver.
- From
OpenQA, - From
Microsoft
If we try to use the one from Microsoft, selenium complains that the EdgeOptions do not have the method .ToCapabilities() (which it doesn't) and we cannot register a RemoteWebDriver
If we use the OpenQA version, we can hit the hub but we get this:
System.InvalidOperationException: 'Unable to create session for <CreateSessionRequest with Capabilities {browserName: MicrosoftEdge, ms:edgeChromium: true, ms:edgeOptions: {}, pageLoadStrategy: normal}>
Build info: version: '4.0.0-alpha-7', revision: 'bd15e4e88a'
System info: host: '9a1032dfe0c9', ip: 'x.x.x.x', os.name: 'Linux', os.arch: 'amd64', os.version: '4.19.76-linuxkit', java.version: '1.8.0_265'
Driver info: driver.version: unknown
Build info: version: '4.0.0-alpha-7', revision: 'bd15e4e88a'
System info: host: '7636feee799f', ip: 'x.x.x.x', os.name: 'Linux', os.arch: 'amd64', os.version: '4.19.76-linuxkit', java.version: '1.8.0_265'
Driver info: driver.version: unknown (SessionNotCreated)'
The setup is the following:
- The browser is in a docker container with Ubuntu running (the browser was tested with VNC and it works)
- The hub is on the official Selenium 4 docker container
- The tests or on a separate docker container running
.Net Core 2.2
Does anyone have any examples of how to initialize the driver from C# to actually run tests?