Commit 4b09763e authored by Rémy Coutable's avatar Rémy Coutable

test: Refresh the page to avoid flakiness

Signed-off-by: default avatarRémy Coutable <remy@rymai.me>
parent 618f5977
......@@ -13,10 +13,13 @@ RSpec.describe 'issue state', :js do
shared_examples 'issue closed' do |selector|
it 'can close an issue' do
wait_for_requests
expect(find('.status-box')).to have_content 'Open'
within selector do
click_button 'Close issue'
wait_for_requests
end
expect(find('.status-box')).to have_content 'Closed'
......@@ -25,10 +28,13 @@ RSpec.describe 'issue state', :js do
shared_examples 'issue reopened' do |selector|
it 'can reopen an issue' do
wait_for_requests
expect(find('.status-box')).to have_content 'Closed'
within selector do
click_button 'Reopen issue'
wait_for_requests
end
expect(find('.status-box')).to have_content 'Open'
......
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