diff options
author | Robert Speicher <rspeicher@gmail.com> | 2017-09-01 15:50:42 -0400 |
---|---|---|
committer | Robert Speicher <rspeicher@gmail.com> | 2017-09-05 10:12:12 -0400 |
commit | 366ebe8b13ec0b92cfef7a2317b6003577e323bf (patch) | |
tree | 6183163ac706b8bc6bbba1e1a607276f23938687 | |
parent | bc9550cbba76a074b76e194cc9ab5d9065a13c14 (diff) | |
download | gitlab-ce-366ebe8b13ec0b92cfef7a2317b6003577e323bf.tar.gz |
Fix failures introduced by Capybara upgraders-update-capybara
-rw-r--r-- | spec/features/dashboard/projects_spec.rb | 6 | ||||
-rw-r--r-- | spec/features/merge_requests/diff_notes_resolve_spec.rb | 5 | ||||
-rw-r--r-- | spec/features/projects/files/creating_a_file_spec.rb | 2 | ||||
-rw-r--r-- | spec/features/search_spec.rb | 4 |
4 files changed, 9 insertions, 8 deletions
diff --git a/spec/features/dashboard/projects_spec.rb b/spec/features/dashboard/projects_spec.rb index 06a43909053..71de9f04653 100644 --- a/spec/features/dashboard/projects_spec.rb +++ b/spec/features/dashboard/projects_spec.rb @@ -115,9 +115,9 @@ feature 'Dashboard Projects' do expect(page).to have_selector('.merge-request-form') expect(current_path).to eq project_new_merge_request_path(project) - expect(find('#merge_request_target_project_id').value).to eq project.id.to_s - expect(find('input#merge_request_source_branch').value).to eq 'feature' - expect(find('input#merge_request_target_branch').value).to eq 'master' + expect(find('#merge_request_target_project_id', visible: false).value).to eq project.id.to_s + expect(find('input#merge_request_source_branch', visible: false).value).to eq 'feature' + expect(find('input#merge_request_target_branch', visible: false).value).to eq 'master' end end end diff --git a/spec/features/merge_requests/diff_notes_resolve_spec.rb b/spec/features/merge_requests/diff_notes_resolve_spec.rb index ac7f75bd308..fd110e68e84 100644 --- a/spec/features/merge_requests/diff_notes_resolve_spec.rb +++ b/spec/features/merge_requests/diff_notes_resolve_spec.rb @@ -196,10 +196,11 @@ feature 'Diff notes resolve', js: true do end it 'does not mark discussion as resolved when resolving single note' do - page.first '.diff-content .note' do + page.within("#note_#{note.id}") do first('.line-resolve-btn').click - expect(page).to have_selector('.note-action-button .loading') + wait_for_requests + expect(first('.line-resolve-btn')['data-original-title']).to eq("Resolved by #{user.name}") end diff --git a/spec/features/projects/files/creating_a_file_spec.rb b/spec/features/projects/files/creating_a_file_spec.rb index e13bf4b6089..e1852a6e544 100644 --- a/spec/features/projects/files/creating_a_file_spec.rb +++ b/spec/features/projects/files/creating_a_file_spec.rb @@ -14,7 +14,7 @@ feature 'User wants to create a file' do file_name = find('#file_name') file_name.set options[:file_name] || 'README.md' - file_content = find('#file-content') + file_content = find('#file-content', visible: false) file_content.set options[:file_content] || 'Some content' click_button 'Commit changes' diff --git a/spec/features/search_spec.rb b/spec/features/search_spec.rb index 05a089641f1..8f6d0bb9d1b 100644 --- a/spec/features/search_spec.rb +++ b/spec/features/search_spec.rb @@ -295,7 +295,7 @@ describe "Search" do fill_in 'search', with: 'foo' click_button 'Search' - expect(find('#group_id').value).to eq(project.namespace.id.to_s) + expect(find('#group_id', visible: false).value).to eq(project.namespace.id.to_s) end it 'preserves the project being searched in' do @@ -304,7 +304,7 @@ describe "Search" do fill_in 'search', with: 'foo' click_button 'Search' - expect(find('#project_id').value).to eq(project.id.to_s) + expect(find('#project_id', visible: false).value).to eq(project.id.to_s) end end end |