Adapt tests to new, pickier Capybara

This commit is contained in:
James Mason 2018-11-19 09:36:39 -08:00
parent 287344e816
commit 0a5246388f
4 changed files with 8 additions and 12 deletions

View file

@ -69,7 +69,7 @@ feature Role do
bootstrap_switch = first('td').find('.bootstrap-switch-container')
bootstrap_switch.click
expect(find('.alert').text).to eq "× Successfully removed role #{role_name} from user #{user_with_role.email}"
expect(page).to have_css('.alert', text: "Successfully removed role #{role_name} from user #{user_with_role.email}")
expect(by_role_name).to eq(role_name) | eq('organizer')
user_with_role.reload
expect(user_with_role.has_cached_role?(role_name, conference)).to eq false