Geckodriver: how to point "moz: firefoxOptions" to node.config for selenium mesh

I run tests on selenium mesh using nunit C # c:

  • selenium-standalone-server: v3.3.1
  • selenium webdriver: v3.3
  • geckodriver: 0.15
  • firefox: v52

Firefox is not installed in the default location, so I get the following exception when running tests:

The expected binary location of the browser, but unable to find the default binary, is not provided with the option "moz: firefoxOptions.binary", and the binary flag is not set on the command line (WARNING: the server did not provide any information about the stack)

I want to specify the Firefox executable path in the capabilities section of node.configthe selenium grid file . How do I do this with the new geckodriver?

firefox_binarynow deprecated and used "moz:firefoxOptions", but I do not know how to specify it in the selenium node configuration file.

This is what I do in the configuration file but it does not work:

{
  "capabilities":
  [
    {
      "platform": "WINDOWS",
      "browserName": "firefox",
      "moz:firefoxOptions": {
        "binary": "D:\\Browsers\\Mozilla Firefox\\firefox.exe"
        },
      "maxInstances": 1,
      "seleniumProtocol": "WebDriver"
    }
  ]
.........
+6
source share

Source: https://habr.com/ru/post/1015813/


All Articles