diff options
author | Olivier Gonzalez <ogonzalez@gitlab.com> | 2019-02-15 13:47:13 +0300 |
---|---|---|
committer | Grzegorz Bizon <grzegorz@gitlab.com> | 2019-02-15 13:47:13 +0300 |
commit | b079a6b6bbe67b00c6ab181058ee2383e1b3c7de (patch) | |
tree | ec2b1e2d5ac3bacccc3a2d80abe3b7a34bc904ba /spec/models | |
parent | ecb1411fbb057e65d3efea53854ba2efc16cb6d3 (diff) |
Base pipeline must be from target branch
Diffstat (limited to 'spec/models')
-rw-r--r-- | spec/models/merge_request_spec.rb | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/spec/models/merge_request_spec.rb b/spec/models/merge_request_spec.rb index afa87b8a62d..fbd19b024a0 100644 --- a/spec/models/merge_request_spec.rb +++ b/spec/models/merge_request_spec.rb @@ -2604,8 +2604,9 @@ describe MergeRequest do let!(:first_pipeline) { create(:ci_pipeline_without_jobs, pipeline_arguments) } let!(:last_pipeline) { create(:ci_pipeline_without_jobs, pipeline_arguments) } + let!(:last_pipeline_with_other_ref) { create(:ci_pipeline_without_jobs, pipeline_arguments.merge(ref: 'other')) } - it 'returns latest pipeline' do + it 'returns latest pipeline for the target branch' do expect(merge_request.base_pipeline).to eq(last_pipeline) end end |