Sha256: 51b0a8c188ed97a97165b64c7753e07f9c58897dc838d86edb37f794dc080804
Contents?: true
Size: 292 Bytes
Versions: 3
Compression:
Stored size: 292 Bytes
Contents
# thanks to thoughtbot http://tinyurl.com/naqu82j module WaitForAjax def wait_for_ajax Timeout.timeout(Capybara.default_wait_time) do loop until finished_all_ajax_requests? end end def finished_all_ajax_requests? page.evaluate_script('jQuery.active').zero? end end
Version data entries
3 entries across 3 versions & 1 rubygems
Version | Path |
---|---|
mutton-0.0.12 | test/support/wait_for_ajax.rb |
mutton-0.0.11 | test/support/wait_for_ajax.rb |
mutton-0.0.10 | test/support/wait_for_ajax.rb |