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/factories/ci/processable.rb')
-rw-r--r--spec/factories/ci/processable.rb10
1 files changed, 10 insertions, 0 deletions
diff --git a/spec/factories/ci/processable.rb b/spec/factories/ci/processable.rb
index 49756433713..c84a2d5d93d 100644
--- a/spec/factories/ci/processable.rb
+++ b/spec/factories/ci/processable.rb
@@ -11,6 +11,10 @@ FactoryBot.define do
scheduling_type { 'stage' }
partition_id { pipeline.partition_id }
+ options do
+ {}
+ end
+
# This factory was updated to help with the efforts of the removal of `ci_builds.stage`:
# https://gitlab.com/gitlab-org/gitlab/-/issues/364377
# These additions can be removed once the specs that use the stage attribute have been updated
@@ -52,5 +56,11 @@ FactoryBot.define do
processable.resource_group = create(:ci_resource_group, project: processable.project)
end
end
+
+ trait :interruptible do
+ after(:build) do |processable|
+ processable.metadata.interruptible = true
+ end
+ end
end
end