Selenium geckodriver executes findElement 10 times slower than chromedriver (.Net)

后端 未结 3 470
南笙
南笙 2021-01-06 11:00

Sorry didn\'t find a similar question and maybe somebody can help.

Due to additional requirements we have to test our project not only with Chrome but with Firefox

3条回答
  •  轮回少年
    2021-01-06 11:32

    By referring to the previous answer, my issue was solved by below code.

    string geckoDriverDirectory = "Path of geckodriver.exe"
    FirefoxDriverService geckoService = 
    FirefoxDriverService.CreateDefaultService(geckoDriverDirectory);
    geckoService.Host = "::1";
    var firefoxOptions = new FirefoxOptions();
    firefoxOptions.AcceptInsecureCertificates = true;
    Driver = new FirefoxDriver(geckoService, firefoxOptions);
    

提交回复
热议问题