对URL http://127.0.0.1:4723/wd/hub/session的远程WebDriver服务器的HTTP请求在30秒后超时

时间:2017-08-13 06:22:46

标签: c# selenium automation appium

我正试图在桌面移动设备上运行自动化。我在移动设备上运行自动化时遇到超时异常。我也禁用了防火墙。有谁可以帮助我。甚至,我增加了3分钟的时间,但也没有帮助我。

DesiredCapabilities capabilities = new DesiredCapabilities();
capabilities.SetCapability("device", "Android");
capabilities.SetCapability("browserName", "chrome");
capabilities.SetCapability("deviceName", "Motorola Moto g");
capabilities.SetCapability("platformName", "Android");
capabilities.SetCapability("platformVersion", "7.0");

driver = new AndroidDriver<IWebElement>(new Uri("http://127.0.0.1:4723/wd/hub"), capabilities, TimeSpan.FromSeconds(30));
driver.Navigate().GoToUrl("www.facebook.com");

0 个答案:

没有答案