demarches-normaliennes/spec/support/wait_for_ajax.rb

10 lines
201 B
Ruby
Raw Normal View History

module WaitForAjax
def wait_for_ajax
expect(page).to have_selector('body[data-active-requests-count="0"]')
end
end
RSpec.configure do |config|
config.include WaitForAjax, type: :feature
end