Add strategy for DockerContainerPool
In order to provide an alternative to Poseidon, a strategy for the DockerContainerPool is added that is used by the runner model. Co-authored-by: Sebastian Serth <Sebastian.Serth@hpi.de>
This commit is contained in:

committed by
Sebastian Serth

parent
1d3f0d7ad8
commit
704407b9fc
15
spec/lib/runner/strategy/docker_container_pool_spec.rb
Normal file
15
spec/lib/runner/strategy/docker_container_pool_spec.rb
Normal file
@ -0,0 +1,15 @@
|
||||
# frozen_string_literal: true
|
||||
|
||||
require 'rails_helper'
|
||||
|
||||
describe Runner::Strategy::DockerContainerPool do
|
||||
let(:runner_id) { FactoryBot.attributes_for(:runner)[:runner_id] }
|
||||
let(:execution_environment) { FactoryBot.create :ruby }
|
||||
let(:container_pool) { described_class.new(runner_id, execution_environment) }
|
||||
|
||||
# TODO: add tests for these methods when implemented
|
||||
it 'defines all methods all runner management strategies must define' do
|
||||
expect(container_pool.public_methods).to include(:destroy_at_management, :copy_files, :attach_to_execution)
|
||||
expect(described_class.public_methods).to include(:request_from_management)
|
||||
end
|
||||
end
|
Reference in New Issue
Block a user