Wait for conditions in RSpec