summaryrefslogtreecommitdiff
path: root/spec/services/ci/create_pipeline_service_spec.rb
diff options
context:
space:
mode:
Diffstat (limited to 'spec/services/ci/create_pipeline_service_spec.rb')
-rw-r--r--spec/services/ci/create_pipeline_service_spec.rb11
1 files changed, 3 insertions, 8 deletions
diff --git a/spec/services/ci/create_pipeline_service_spec.rb b/spec/services/ci/create_pipeline_service_spec.rb
index be4abf11cf4..41ce81e0651 100644
--- a/spec/services/ci/create_pipeline_service_spec.rb
+++ b/spec/services/ci/create_pipeline_service_spec.rb
@@ -519,21 +519,16 @@ describe Ci::CreatePipelineService do
end
end
- context 'when pipelie is running for a tag' do
+ context 'when pipeline is running for a tag' do
before do
- allow_any_instance_of(Repository)
- .to receive(:tag_exists?).and_return(false)
- allow_any_instance_of(Repository)
- .to receive(:tag_exists?).with('refs/tags/mytag').and_return(true)
-
config = YAML.dump(test: { script: 'test', only: ['branches'] },
- deploy: { script: 'deploy', only: ['tags'] })
+ deploy: { script: 'deploy', only: ['tags'] })
stub_ci_pipeline_yaml_file(config)
end
it 'creates a tagged pipeline' do
- pipeline = execute_service(ref: 'mytag')
+ pipeline = execute_service(ref: 'v1.0.0')
expect(pipeline.tag?).to be true
end