Use to_reference for issue and merge request mentionable specs
This commit is contained in:
parent
15133d99de
commit
213d1a4768
2 changed files with 4 additions and 4 deletions
|
@ -70,7 +70,7 @@ describe Issue do
|
|||
it_behaves_like 'an editable mentionable' do
|
||||
subject { create(:issue, project: project) }
|
||||
|
||||
let(:backref_text) { "issue ##{subject.iid}" }
|
||||
let(:backref_text) { "issue #{subject.to_reference}" }
|
||||
let(:set_mentionable_text) { ->(txt){ subject.description = txt } }
|
||||
end
|
||||
|
||||
|
|
|
@ -165,10 +165,10 @@ describe MergeRequest do
|
|||
end
|
||||
|
||||
it_behaves_like 'an editable mentionable' do
|
||||
subject { create(:merge_request, source_project: project, target_project: project) }
|
||||
subject { create(:merge_request, source_project: project) }
|
||||
|
||||
let(:backref_text) { "merge request !#{subject.iid}" }
|
||||
let(:set_mentionable_text) { ->(txt){ subject.title = txt } }
|
||||
let(:backref_text) { "merge request #{subject.to_reference}" }
|
||||
let(:set_mentionable_text) { ->(txt){ subject.description = txt } }
|
||||
end
|
||||
|
||||
it_behaves_like 'a Taskable' do
|
||||
|
|
Loading…
Reference in a new issue