From 1c6e8c149861e1027da40622536b5276c46a7408 Mon Sep 17 00:00:00 2001 From: GitLab Bot Date: Mon, 8 Feb 2021 09:09:30 +0000 Subject: Add latest changes from gitlab-org/gitlab@master --- spec/lib/gitlab/data_builder/pipeline_spec.rb | 11 +++++++++++ 1 file changed, 11 insertions(+) (limited to 'spec/lib/gitlab/data_builder') diff --git a/spec/lib/gitlab/data_builder/pipeline_spec.rb b/spec/lib/gitlab/data_builder/pipeline_spec.rb index 32619fc4c37..fd7cadeb89e 100644 --- a/spec/lib/gitlab/data_builder/pipeline_spec.rb +++ b/spec/lib/gitlab/data_builder/pipeline_spec.rb @@ -104,5 +104,16 @@ RSpec.describe Gitlab::DataBuilder::Pipeline do expect(merge_request_attrs[:url]).to eq("http://localhost/#{merge_request.target_project.full_path}/-/merge_requests/#{merge_request.iid}") end end + + context 'when pipeline has retried builds' do + before do + create(:ci_build, :retried, pipeline: pipeline) + end + + it 'does not contain retried builds in payload' do + expect(data[:builds].count).to eq(1) + expect(build_data[:id]).to eq(build.id) + end + end end end -- cgit v1.2.3