Commit 6f29026f authored by Robert Speicher's avatar Robert Speicher

Fix failures introduced by Capybara upgrade

parent ecb879f6
...@@ -115,9 +115,9 @@ feature 'Dashboard Projects' do ...@@ -115,9 +115,9 @@ feature 'Dashboard Projects' do
expect(page).to have_selector('.merge-request-form') expect(page).to have_selector('.merge-request-form')
expect(current_path).to eq project_new_merge_request_path(project) 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('#merge_request_target_project_id', visible: false).value).to eq project.id.to_s
expect(find('input#merge_request_source_branch').value).to eq 'feature' expect(find('input#merge_request_source_branch', visible: false).value).to eq 'feature'
expect(find('input#merge_request_target_branch').value).to eq 'master' expect(find('input#merge_request_target_branch', visible: false).value).to eq 'master'
end end
end end
end end
...@@ -196,10 +196,11 @@ feature 'Diff notes resolve', js: true do ...@@ -196,10 +196,11 @@ feature 'Diff notes resolve', js: true do
end end
it 'does not mark discussion as resolved when resolving single note' do 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 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}") expect(first('.line-resolve-btn')['data-original-title']).to eq("Resolved by #{user.name}")
end end
......
...@@ -14,7 +14,7 @@ feature 'User wants to create a file' do ...@@ -14,7 +14,7 @@ feature 'User wants to create a file' do
file_name = find('#file_name') file_name = find('#file_name')
file_name.set options[:file_name] || 'README.md' 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' file_content.set options[:file_content] || 'Some content'
click_button 'Commit changes' click_button 'Commit changes'
......
...@@ -295,7 +295,7 @@ describe "Search" do ...@@ -295,7 +295,7 @@ describe "Search" do
fill_in 'search', with: 'foo' fill_in 'search', with: 'foo'
click_button 'Search' 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 end
it 'preserves the project being searched in' do it 'preserves the project being searched in' do
...@@ -304,7 +304,7 @@ describe "Search" do ...@@ -304,7 +304,7 @@ describe "Search" do
fill_in 'search', with: 'foo' fill_in 'search', with: 'foo'
click_button 'Search' 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 end
end end
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