Introduce strategy for runner behavior

The runner model is only a class responsible for storing information
now. Based on the configuration it picks a strategy for the runner
management. The Poseidon strategy is already implemented and tested.
The Docker strategy will follow.
This commit is contained in:
Felix Auringer
2021-06-09 09:39:56 +02:00
committed by Sebastian Serth
parent cf58be97ee
commit d0d1b1bffd
13 changed files with 541 additions and 433 deletions

View File

@ -3,7 +3,7 @@
# This factory does not request the runner management as the id is already provided.
FactoryBot.define do
factory :runner do
runner_id { 'test-runner-id' }
sequence(:runner_id) {|n| "test-runner-id-#{n}" }
association :execution_environment, factory: :ruby
association :user, factory: :external_user
waiting_time { 1.0 }