Update 2014-10-23: tl; dr: enable interactive mode / interactive input.
Longer version: we found a workaround. Enabling interactive mode (mostly an open RDP session) allows you to run tests. Previously, people had to do this in order to get Selenium / etc. to run. In Visual Studio 2010, it has been fixed. But something seems to regress. Our setup is a Windows virtual machine with a TFS build controller component installed on it. Our theory is that something is preventing the assembly controller from interacting with the desktop, or there are various network or security settings that prevent it from interacting with the web server. We are going to open a ticket with Microsoft to see if they can fix this regression.
I am aware of the problem of periodically receiving such timeouts. It's not a problem. I get timeouts in 100% of cases, for ALL Selenium operations (click, find an item, etc.).
My tests worked fine for several days in a row, and then something changed on the server. My WebDriver has not changed. The same ChromeDriver.exe is still used as before. My code has not changed. As far as I know, the definition of the assembly has not changed.
What we tried:
- Turn off the firewall that might interfere
- Reboot server
- Disabling concurrent test runs
- Rollback the latest Windows updates.
I do not know what else to try at this moment. Ideas?
We use .NET bindings at version 2.40 level. (I know update 2.43.1 there, but I doubt it will help). ChromeDriver.exe should be the latest stable version; I checked it recently.
Error message:
.BlackBoxTests.WebUI.Portal.Tests.LocationsShould.AddPlan :
OpenQA.Selenium.WebDriverException: HTTP- WebDriver URL http://localhost:40901/session/37a7c64c5ef189acf896ff9d3af34e67/execute 60 . --- > System.Net.WebException:
:
System.Net.HttpWebRequest.GetResponse()
OpenQA.Selenium.Remote.HttpCommandExecutor.CreateResponse(WebRequest request)
OpenQA.Selenium.Remote.HttpCommandExecutor.CreateResponse(WebRequest request)
OpenQA.Selenium.Remote.HttpCommandExecutor.Execute(Command commandToExecute)
OpenQA.Selenium.Remote.DriverServiceCommandExecutor.Execute(Command commandToExecute)
OpenQA.Selenium.Remote.RemoteWebDriver.Execute(String driverCommandToExecute, Dictionary`2 parameters)
OpenQA.Selenium.Remote.RemoteWebDriver.ExecuteScriptCommand(String script, String commandName, Object[] args)
OpenQA.Selenium.Remote.RemoteWebDriver.ExecuteScript(String script, Object[] args)
Company.BlackBoxTests.WebUI.Portal.PageObjects.BasePage.WaitForAjax(IWebDriver driver, String action, Boolean longWait)