X-Git-Url: https://git.arvados.org/arvados.git/blobdiff_plain/12df34cfd4be1282b03db76beb85df7709fdf4a0..1ec89c1c31669eb89bd1997cfa9d3c50f0204dbe:/apps/workbench/test/integration/collection_upload_test.rb diff --git a/apps/workbench/test/integration/collection_upload_test.rb b/apps/workbench/test/integration/collection_upload_test.rb index 9a2637365c..a2405765b0 100644 --- a/apps/workbench/test/integration/collection_upload_test.rb +++ b/apps/workbench/test/integration/collection_upload_test.rb @@ -1,10 +1,6 @@ require 'integration_helper' class CollectionUploadTest < ActionDispatch::IntegrationTest - setup do - Headless.new.start - end - setup do testfiles.each do |filename, content| open(testfile_path(filename), 'w') do |io| @@ -20,7 +16,7 @@ class CollectionUploadTest < ActionDispatch::IntegrationTest end test "Create new collection using upload button" do - Capybara.current_driver = :poltergeist + need_javascript visit page_with_token 'active', aproject_path find('.btn', text: 'Add data').click click_link 'Upload files from my computer' @@ -32,14 +28,14 @@ class CollectionUploadTest < ActionDispatch::IntegrationTest end test "No Upload tab on non-writable collection" do - Capybara.current_driver = :poltergeist + need_javascript visit(page_with_token 'active', '/collections/'+api_fixture('collections')['user_agreement']['uuid']) assert_no_selector '.nav-tabs Upload' end test "Upload two empty files with the same name" do - Capybara.current_driver = :selenium + need_selenium "to make file uploads work" visit page_with_token 'active', sandbox_path find('.nav-tabs a', text: 'Upload').click attach_file 'file_selector', testfile_path('empty.txt') @@ -53,14 +49,14 @@ class CollectionUploadTest < ActionDispatch::IntegrationTest end test "Upload non-empty files, report errors" do - Capybara.current_driver = :selenium + need_selenium "to make file uploads work" visit page_with_token 'active', sandbox_path find('.nav-tabs a', text: 'Upload').click attach_file 'file_selector', testfile_path('a') attach_file 'file_selector', testfile_path('foo.txt') assert_selector 'button:not([disabled])', text: 'Start' click_button 'Start' - if "test environment does not have a keepproxy yet, see #4534" + if "test environment does not have a keepproxy yet, see #4534" != "fixed" using_wait_time 20 do assert_text :visible, 'error' end