summaryrefslogtreecommitdiff
path: root/spec/models/ci/pipeline_spec.rb
diff options
context:
space:
mode:
authorMatija Čupić <matteeyah@gmail.com>2018-11-10 14:34:53 +0100
committerMatija Čupić <matteeyah@gmail.com>2018-12-08 19:25:44 +0100
commit1bf580688890a3b13e7ac0468f29108dafe08f9e (patch)
tree634f058f9c005e1b15d5df88d14b0d25bacb40e4 /spec/models/ci/pipeline_spec.rb
parentb278d886ba65e2d3d438352b6243cd33b1ba4636 (diff)
downloadgitlab-ce-1bf580688890a3b13e7ac0468f29108dafe08f9e.tar.gz
Use full ref when possible to avoid ambiguity
Diffstat (limited to 'spec/models/ci/pipeline_spec.rb')
-rw-r--r--spec/models/ci/pipeline_spec.rb4
1 files changed, 4 insertions, 0 deletions
diff --git a/spec/models/ci/pipeline_spec.rb b/spec/models/ci/pipeline_spec.rb
index b67c6a4cffa..17f33785fda 100644
--- a/spec/models/ci/pipeline_spec.rb
+++ b/spec/models/ci/pipeline_spec.rb
@@ -397,6 +397,10 @@ describe Ci::Pipeline, :mailer do
end
describe '#protected_ref?' do
+ before do
+ pipeline.project = create(:project, :repository)
+ end
+
it 'delegates method to project' do
expect(pipeline).not_to be_protected_ref
end