Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'spec/lib/gitlab/ci/pipeline')
-rw-r--r--spec/lib/gitlab/ci/pipeline/chain/seed_spec.rb4
-rw-r--r--spec/lib/gitlab/ci/pipeline/chain/sequence_spec.rb15
-rw-r--r--spec/lib/gitlab/ci/pipeline/seed/build/cache_spec.rb2
3 files changed, 19 insertions, 2 deletions
diff --git a/spec/lib/gitlab/ci/pipeline/chain/seed_spec.rb b/spec/lib/gitlab/ci/pipeline/chain/seed_spec.rb
index aa54f19b26c..1e1d5c2a724 100644
--- a/spec/lib/gitlab/ci/pipeline/chain/seed_spec.rb
+++ b/spec/lib/gitlab/ci/pipeline/chain/seed_spec.rb
@@ -39,6 +39,10 @@ describe Gitlab::Ci::Pipeline::Chain::Seed do
expect(pipeline.iid).to be_present
end
+ it 'ensures ci_ref' do
+ expect(pipeline.ci_ref).to be_present
+ end
+
it 'sets the seeds in the command object' do
expect(command.stage_seeds).to all(be_a Gitlab::Ci::Pipeline::Seed::Base)
expect(command.stage_seeds.count).to eq 1
diff --git a/spec/lib/gitlab/ci/pipeline/chain/sequence_spec.rb b/spec/lib/gitlab/ci/pipeline/chain/sequence_spec.rb
index f82e49f9323..ea04862ed74 100644
--- a/spec/lib/gitlab/ci/pipeline/chain/sequence_spec.rb
+++ b/spec/lib/gitlab/ci/pipeline/chain/sequence_spec.rb
@@ -56,11 +56,24 @@ describe Gitlab::Ci::Pipeline::Chain::Sequence do
end
it 'adds sequence duration to duration histogram' do
- allow(command).to receive(:duration_histogram).and_return(histogram)
+ allow(command.metrics)
+ .to receive(:pipeline_creation_duration_histogram)
+ .and_return(histogram)
subject.build!
expect(histogram).to have_received(:observe)
end
+
+ it 'records pipeline size by pipeline source in a histogram' do
+ allow(command.metrics)
+ .to receive(:pipeline_size_histogram)
+ .and_return(histogram)
+
+ subject.build!
+
+ expect(histogram).to have_received(:observe)
+ .with({ source: 'push' }, 0)
+ end
end
end
diff --git a/spec/lib/gitlab/ci/pipeline/seed/build/cache_spec.rb b/spec/lib/gitlab/ci/pipeline/seed/build/cache_spec.rb
index fe19244659f..f5b43b5aeab 100644
--- a/spec/lib/gitlab/ci/pipeline/seed/build/cache_spec.rb
+++ b/spec/lib/gitlab/ci/pipeline/seed/build/cache_spec.rb
@@ -134,7 +134,7 @@ describe Gitlab::Ci::Pipeline::Seed::Build::Cache do
it_behaves_like 'foo/bar directory key'
end
- context 'with directories ending in slash star' do
+ context 'with directories ending in slash star', quarantine: 'https://gitlab.com/gitlab-org/gitlab/-/issues/222356' do
let(:files) { ['foo/bar/*'] }
it_behaves_like 'foo/bar directory key'