Commit 0c7e1c16 authored by Rémy Coutable's avatar Rémy Coutable

wait_for_requests is not needed when AJAX is not in play

Also, using page.current_path instead of current_url and move the URL
expectation after the page content expectations.
Signed-off-by: default avatarRémy Coutable <remy@rymai.me>
parent f7e7e40d
...@@ -41,13 +41,10 @@ feature 'issue move to another project' do ...@@ -41,13 +41,10 @@ feature 'issue move to another project' do
find('#issuable-move', visible: false).set(new_project.id) find('#issuable-move', visible: false).set(new_project.id)
click_button('Save changes') click_button('Save changes')
wait_for_requests
expect(current_url).to include project_path(new_project)
expect(page).to have_content("Text with #{cross_reference}#{mr.to_reference}") expect(page).to have_content("Text with #{cross_reference}#{mr.to_reference}")
expect(page).to have_content("moved from #{cross_reference}#{issue.to_reference}") expect(page).to have_content("moved from #{cross_reference}#{issue.to_reference}")
expect(page).to have_content(issue.title) expect(page).to have_content(issue.title)
expect(page.current_path).to include project_path(new_project)
end end
scenario 'searching project dropdown', js: true do scenario 'searching project dropdown', js: true do
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment