How to keep a capybara webdriver browser session alive for more than 15 mins?

时间:2019-05-31 11:47:50

标签: ruby selenium-webdriver webdriver capybara session-timeout

i.e. How to set webdriver script timeout in Ruby with Capybara.

I am driving a browser application through Ruby with Selenium Webdriver and Capybara

I am polling a website. If the polling gap is 8 minutes, no problem. If the polling gap is more than about 10- 15 minutes I find I am logged out of the application the next time I try to visit a page. It seems that the webdriver session is ended. This does not happen to me when using the application website myserlf - I can stay logged in all day without any actions. I am not timed out. This is why I believe the issue is in the webdriver session timeout

This is NOT about the usual find element category of timeout that is the genesis of most questions about webdriver timeout. This is the timeout for the session itself.

I create the webdriver session with

@session = Capybara::Session.new(:chrome)

0 个答案:

没有答案