summaryrefslogtreecommitdiff
path: root/spec/helpers/notes_helper_spec.rb
diff options
context:
space:
mode:
authorConstance Okoghenun <constanceokoghenun@gmail.com>2019-01-17 12:15:33 +0100
committerConstance Okoghenun <constanceokoghenun@gmail.com>2019-01-17 12:15:33 +0100
commitc1c0c0c21b075ee9ee2eddb75ad9681f29765bb2 (patch)
tree81b8fac501896868be78ecefb1cda93188a3d24d /spec/helpers/notes_helper_spec.rb
parenteec16ee28c7b377101ab3d5f81835cd8c2020981 (diff)
downloadgitlab-ce-c1c0c0c21b075ee9ee2eddb75ad9681f29765bb2.tar.gz
Display "commented" only for commit discussions on merge requests
Add commit prop to NoteableNote component and pass it from NoteableDiscussion
Diffstat (limited to 'spec/helpers/notes_helper_spec.rb')
-rw-r--r--spec/helpers/notes_helper_spec.rb4
1 files changed, 2 insertions, 2 deletions
diff --git a/spec/helpers/notes_helper_spec.rb b/spec/helpers/notes_helper_spec.rb
index 21461e46cf4..0715f34dafe 100644
--- a/spec/helpers/notes_helper_spec.rb
+++ b/spec/helpers/notes_helper_spec.rb
@@ -185,8 +185,8 @@ describe NotesHelper do
context 'for a non-diff discussion' do
let(:discussion) { create(:discussion_note_on_commit, project: project).to_discussion }
- it 'returns the commit path' do
- expect(helper.discussion_path(discussion)).to eq(project_commit_path(project, commit))
+ it 'returns the commit path with the note anchor' do
+ expect(helper.discussion_path(discussion)).to eq(project_commit_path(project, commit, anchor: "note_#{discussion.first_note.id}"))
end
end
end