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/runners.rb')
-rw-r--r--spec/factories/ci/runners.rb6
1 files changed, 6 insertions, 0 deletions
diff --git a/spec/factories/ci/runners.rb b/spec/factories/ci/runners.rb
index 4758986b47c..a9a637b4284 100644
--- a/spec/factories/ci/runners.rb
+++ b/spec/factories/ci/runners.rb
@@ -66,6 +66,12 @@ FactoryBot.define do
end
end
+ trait :with_runner_machine do
+ after(:build) do |runner, evaluator|
+ runner.runner_machines << build(:ci_runner_machine, runner: runner)
+ end
+ end
+
trait :inactive do
active { false }
end