The HTTP request to the remote WebDriver server for URL http://127.0.0.1:4723/wd/hub/session timed out after 30 seconds

Viewed 1291

I am trying to run automation in mobile from desktop. I am getting timeout exception while running automation in mobile. I have disabled firewall also. Is anybody can help me here. Even, I increased time out to 3 minutes but also doesn't help me.

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 Answers
Related