Unverified Commit 44224810 authored by Mike Greiling's avatar Mike Greiling
Browse files

prevent race condition when attempting to cancel a file upload

parent 3e1168a1
......@@ -585,9 +585,11 @@
end
it "cancels a file upload correctly" do
dropzone_file([Rails.root.join('spec', 'fixtures', 'dk.png')], 0, false)
slow_requests do
dropzone_file([Rails.root.join('spec', 'fixtures', 'dk.png')], 0, false)
click_button 'Cancel'
click_button 'Cancel'
end
expect(page).to have_button('Attach a file')
expect(page).not_to have_button('Cancel')
......
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