diff options
author | Michel Engelen <michel.engelen@diva-e.com> | 2019-06-14 11:18:03 +0200 |
---|---|---|
committer | Michel Engelen <michel@nomorejs.net> | 2019-07-02 14:29:54 +0200 |
commit | 4169421049e1909bddc49582f7ebd89bd504af00 (patch) | |
tree | d08f1576206ac48b19e288c39cb63dac2c3f0104 /spec | |
parent | 390786d8a53bfb23a677f6b04fdfdfab400eff03 (diff) | |
download | gitlab-ce-4169421049e1909bddc49582f7ebd89bd504af00.tar.gz |
updated tests for !29553
Diffstat (limited to 'spec')
-rw-r--r-- | spec/features/merge_request/user_sees_discussions_spec.rb | 8 | ||||
-rw-r--r-- | spec/features/merge_request/user_sees_merge_button_depending_on_unresolved_discussions_spec.rb | 12 |
2 files changed, 10 insertions, 10 deletions
diff --git a/spec/features/merge_request/user_sees_discussions_spec.rb b/spec/features/merge_request/user_sees_discussions_spec.rb index 57be1d06708..39258b48295 100644 --- a/spec/features/merge_request/user_sees_discussions_spec.rb +++ b/spec/features/merge_request/user_sees_discussions_spec.rb @@ -1,6 +1,6 @@ require 'rails_helper' -describe 'Merge request > User sees discussions', :js do +describe 'Merge request > User sees threads', :js do let(:project) { create(:project, :public, :repository) } let(:user) { project.creator } let(:merge_request) { create(:merge_request, source_project: project) } @@ -30,7 +30,7 @@ describe 'Merge request > User sees discussions', :js do visit project_merge_request_path(project, merge_request) end - context 'active discussions' do + context 'active threads' do it 'shows a link to the diff' do within(".discussion[data-discussion-id='#{active_discussion.id}']") do path = diffs_project_merge_request_path(project, merge_request, anchor: active_discussion.line_code) @@ -39,7 +39,7 @@ describe 'Merge request > User sees discussions', :js do end end - context 'outdated discussions' do + context 'outdated threads' do it 'shows a link to the outdated diff' do within(".discussion[data-discussion-id='#{outdated_discussion.id}']") do path = diffs_project_merge_request_path(project, merge_request, diff_id: old_merge_request_diff.id, anchor: outdated_discussion.line_code) @@ -85,7 +85,7 @@ describe 'Merge request > User sees discussions', :js do it_behaves_like 'a functional discussion' it 'displays correct header' do - expect(page).to have_content "started a discussion on commit #{note.commit_id[0...7]}" + expect(page).to have_content "started a thread on commit #{note.commit_id[0...7]}" end end diff --git a/spec/features/merge_request/user_sees_merge_button_depending_on_unresolved_discussions_spec.rb b/spec/features/merge_request/user_sees_merge_button_depending_on_unresolved_discussions_spec.rb index f6b771facf8..cf398a7df18 100644 --- a/spec/features/merge_request/user_sees_merge_button_depending_on_unresolved_discussions_spec.rb +++ b/spec/features/merge_request/user_sees_merge_button_depending_on_unresolved_discussions_spec.rb @@ -1,6 +1,6 @@ require 'rails_helper' -describe 'Merge request > User sees merge button depending on unresolved discussions', :js do +describe 'Merge request > User sees merge button depending on unresolved threads', :js do let(:project) { create(:project, :repository) } let(:user) { project.creator } let!(:merge_request) { create(:merge_request_with_diff_notes, source_project: project, author: user) } @@ -16,14 +16,14 @@ describe 'Merge request > User sees merge button depending on unresolved discuss visit project_merge_request_path(project, merge_request) end - context 'with unresolved discussions' do + context 'with unresolved threads' do it 'does not allow to merge' do expect(page).not_to have_button 'Merge' - expect(page).to have_content('There are unresolved discussions.') + expect(page).to have_content('There are unresolved threads.') end end - context 'with all discussions resolved' do + context 'with all threads resolved' do before do merge_request.discussions.each { |d| d.resolve!(user) } visit project_merge_request_path(project, merge_request) @@ -41,13 +41,13 @@ describe 'Merge request > User sees merge button depending on unresolved discuss visit project_merge_request_path(project, merge_request) end - context 'with unresolved discussions' do + context 'with unresolved threads' do it 'does not allow to merge' do expect(page).to have_button 'Merge' end end - context 'with all discussions resolved' do + context 'with all threads resolved' do before do merge_request.discussions.each { |d| d.resolve!(user) } visit project_merge_request_path(project, merge_request) |