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:
authorGitLab Bot <gitlab-bot@gitlab.com>2021-06-11 21:10:13 +0300
committerGitLab Bot <gitlab-bot@gitlab.com>2021-06-11 21:10:13 +0300
commite58ce90f147742c314b9cc08c2d1c0b585e39cf9 (patch)
tree467a1716bb63f4061e57b824c0e07532ca2fba4c /spec/factories/ci
parent62cd7010ef91dcaa5a5a36790985053db0b38671 (diff)
Add latest changes from gitlab-org/gitlab@master
Diffstat (limited to 'spec/factories/ci')
-rw-r--r--spec/factories/ci/builds.rb14
1 files changed, 14 insertions, 0 deletions
diff --git a/spec/factories/ci/builds.rb b/spec/factories/ci/builds.rb
index 55be7fd72b0..b8f57b23f68 100644
--- a/spec/factories/ci/builds.rb
+++ b/spec/factories/ci/builds.rb
@@ -238,6 +238,20 @@ FactoryBot.define do
coverage_regex { '/(d+)/' }
end
+ trait :trace_with_coverage do
+ coverage { nil }
+ coverage_regex { '(\d+\.\d+)%' }
+
+ transient do
+ trace_coverage { 60.0 }
+ end
+
+ after(:create) do |build, evaluator|
+ build.trace.set("Coverage #{evaluator.trace_coverage}%")
+ build.trace.archive! if build.complete?
+ end
+ end
+
trait :trace_live do
after(:create) do |build, evaluator|
build.trace.set('BUILD TRACE')