accept confirmation modal when erasing job trace in user_browses_job_spec.rb

This commit is contained in:
Mike Greiling 2017-10-31 10:01:32 -05:00
parent d5bee2c6e0
commit ae1be64b66
No known key found for this signature in database
GPG key ID: 0303DF507FA67596

View file

@ -21,12 +21,12 @@ describe 'User browses a job', :js do
expect(page).to have_content("Job ##{build.id}")
expect(page).to have_css('#build-trace')
click_link('Erase')
accept_confirm { click_link('Erase') }
expect(page).to have_no_css('.artifacts')
expect(build).not_to have_trace
expect(build.artifacts_file.exists?).to be_falsy
expect(build.artifacts_metadata.exists?).to be_falsy
expect(page).to have_no_css('.artifacts')
page.within('.erased') do
expect(page).to have_content('Job has been erased')