Eventually does not work with RSpec expect statements
adsteel opened this issue · comments
Adam Steel commented
eventually(40) { expect(roles.user).to see :list_item }
The issue is that when the expectation fails, it throws RSpec::Expectations::ExpectationNotMetError
, which subclasses Exception, not StandardError. Eventually only catches StandardError. This means the code above waits only as long as the Capybara wait time (defined in Dill's see?), not the 40 seconds that have been given the eventually
Here's the PR that changed the subclass.
rspec/rspec-expectations#426
Adam Steel commented
Resolved with #107