#381 new
Niall Mullally

Pass on click_link/click_button options to selenium RC

Reported by Niall Mullally | June 8th, 2010 @ 07:52 AM

I've run into problems with selenium tests timing out and it is often related to the page not being fully loaded. The Webrat technique of waiting for the target element to load, with a timeout of 5 seconds, isn't always reliable.

I have found explicitly telling selenium to wait for the page to fully load has eliminated the timeout issues I was having.

Rather than littering tests with 'selenium.wait_for_page_to_load', this patch updates Webrat::SeleniumSession's #click_link, #click_link_within and #click_button methods to pass on the options hash to the Selenium RC.

This allows for calls like click_link('My Link', :wait_for => :page) which is a bit more tidy.

Patch attached and also available on my fork @ http://github.com/Sidane/webrat/commit/10a56aaa80d7463ed4aff8b91497...

Comments and changes to this ticket

Please Sign in or create a free account to add a new ticket.

With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.

New-ticket Create new ticket

Create your profile

Help contribute to this project by taking a few moments to create your personal profile. Create your profile ยป

Ruby Acceptance Testing for Web applications.

Shared Ticket Bins

People watching this ticket

Attachments

Pages