1

I have a selenium test that fills out a form (using latest ChromeDriver) and clicks a submit button. This button then does some calculations which can take up to 5 minutes (its actually generating an SSRS report in the backend, but that shouldnt make any difference)

After 1 minute it fails with this:

No response from server for url http://localhost:53596/session/985300748128c44714abaf1690b52414/element/:wdc:1364433458070/submit

I believe the IWebElement.Submit() and .Click() will block until the page is changed (I dont really want this to happen, Id rather do my own waiting code but I can't see how to click the button without the wait?). If I can't turn this off, can I extend the timeout? I've tried setting the ImplicitylyWait timeout to be 2000 seconds but that doesnt make any difference.

Is anyone able to tell me where this 1 minute timeout is defined and how I can turn it off?

RodH257
  • 3,552
  • 5
  • 36
  • 46

1 Answers1

0

Read about the explicit and implicit waits Webdriver documentation.

In your case you might want to use an explicit wait using WebDriverWait.

Dakshinamurthy Karra
  • 5,353
  • 1
  • 17
  • 28
  • 1
    I think I'm confused as I'm not sure how an explicit wait solves my problem. In the example on the wiki they do this: driver.get("http://somedomain/url_that_delays_loading"); WebElement myDynamicElement = (new WebDriverWait(driver, 10)) .until(.....))); However, in my case, replace the .get with an element .click which blocks until the request has finished (or throws after 1 min). It will never reach the explicit wait. I want to use an explicit wait but how do I stop .click from blocking and timing out after 1 minute so I can use it? – RodH257 Apr 02 '13 at 00:25
  • Have a look at http://stackoverflow.com/questions/5868439/wait-for-page-load-in-selenium. – Dakshinamurthy Karra Apr 02 '13 at 04:16
  • 1
    that link does not really provide any information on how to stop .click from timing out BEFORE the explicit wait is started. The click is triggered, and then you do your explicit wait. – RodH257 Apr 28 '13 at 23:00