A new branch created for a confidential issue is named <id>-confidential-issue
.
This commit is contained in:
parent
aa396ae5ee
commit
f801e2243d
2 changed files with 2 additions and 2 deletions
|
@ -158,7 +158,7 @@ class Issue < ActiveRecord::Base
|
||||||
|
|
||||||
def to_branch_name
|
def to_branch_name
|
||||||
if self.confidential?
|
if self.confidential?
|
||||||
"issue-#{iid}"
|
"#{iid}-confidential-issue"
|
||||||
else
|
else
|
||||||
"#{iid}-#{title.parameterize}"
|
"#{iid}-#{title.parameterize}"
|
||||||
end
|
end
|
||||||
|
|
|
@ -248,7 +248,7 @@ describe Issue, models: true do
|
||||||
|
|
||||||
it "does not contain the issue title if confidential" do
|
it "does not contain the issue title if confidential" do
|
||||||
issue = create(:issue, title: 'testing-issue', confidential: true)
|
issue = create(:issue, title: 'testing-issue', confidential: true)
|
||||||
expect(issue.to_branch_name).to match /\Aissue/
|
expect(issue.to_branch_name).to match /confidential-issue\z/
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in a new issue