spec/lib/worker/configuration_spec.rb in evrone-ci-worker-0.2.0.pre27 vs spec/lib/worker/configuration_spec.rb in evrone-ci-worker-0.2.0.pre28
- old
+ new
@@ -2,38 +2,39 @@
describe Evrone::CI::Worker::Configuration do
let(:config) { Evrone::CI::Worker.config }
subject { config }
- its(:run) { should eq :docker }
- its(:docker) { should be }
- its(:tmp_dir_name) { should eq 'tmp' }
- its(:timeout) { should eq 1800 }
- its(:amqp_url) { should be_nil }
+ its(:run) { should eq :docker }
+ its(:docker) { should be }
+ its(:timeout) { should eq 1800 }
+ its(:amqp_url) { should be_nil }
+ its(:connector_options) { should eq config.docker }
+ its(:connector_remote_dir) { should eq config.docker.remote_dir }
context "docker" do
subject { config.docker }
- its(:ssh) { should be }
- its(:remote_dir) { should eq '/home/ci' }
- its(:init) { should be }
- its(:image) { should eq 'dmexe/ci' }
+ its(:user) { should be }
+ its(:password) { should be }
+ its(:init) { should be }
+ its(:image) { should be }
+ its(:remote_dir) { should be }
end
- context "docker.ssh" do
- subject { config.docker.ssh }
+ context "local" do
+ subject { config.local }
- its(:user) { should eq 'ci' }
- its(:password) { should eq 'ci' }
+ its(:remote_dir){ should be }
end
context ".configure" do
subject {
Evrone::CI::Worker.configure do |c|
c.run = "local"
c.docker.image = 'image'
end
}
- its(:run) { should eq :local }
- its("docker.image") { should eq 'image' }
+ its(:run) { should eq :local }
+ its("docker.image") { should eq 'image' }
end
end