Commit 87345e57 authored by Sasha Gerrand's avatar Sasha Gerrand Committed by Sasha Gerrand
Browse files

Convert runners: Solo -> Server

parent 562c35a2
......@@ -2,7 +2,7 @@ require 'spec_helper'
describe 'rsyslog::client' do
let(:chef_run) do
ChefSpec::SoloRunner.new(platform: 'ubuntu', version: '12.04') do |node|
ChefSpec::ServerRunner.new(platform: 'ubuntu', version: '12.04') do |node|
node.set['rsyslog']['server_ip'] = server_ip
node.set['rsyslog']['custom_remote'] = custom_remote
end.converge(described_recipe)
......@@ -41,7 +41,7 @@ describe 'rsyslog::client' do
context 'on SmartOS' do
let(:chef_run) do
ChefSpec::SoloRunner.new(platform: 'smartos', version: 'joyent_20130111T180733Z') do |node|
ChefSpec::ServerRunner.new(platform: 'smartos', version: 'joyent_20130111T180733Z') do |node|
node.set['rsyslog']['server_ip'] = server_ip
node.set['rsyslog']['custom_remote'] = custom_remote
end.converge(described_recipe)
......@@ -84,7 +84,7 @@ describe 'rsyslog::client' do
context 'on SmartOS' do
let(:chef_run) do
ChefSpec::SoloRunner.new(platform: 'smartos', version: 'joyent_20130111T180733Z') do |node|
ChefSpec::ServerRunner.new(platform: 'smartos', version: 'joyent_20130111T180733Z') do |node|
node.set['rsyslog']['server_ip'] = server_ip
end.converge(described_recipe)
end
......
......@@ -2,7 +2,7 @@ require 'spec_helper'
describe 'rsyslog::default' do
let(:chef_run) do
ChefSpec::SoloRunner.new(platform: 'ubuntu', version: '12.04').converge(described_recipe)
ChefSpec::ServerRunner.new(platform: 'ubuntu', version: '12.04').converge(described_recipe)
end
let(:service_resource) { 'service[rsyslog]' }
......@@ -13,7 +13,7 @@ describe 'rsyslog::default' do
context "when node['rsyslog']['relp'] is true" do
let(:chef_run) do
ChefSpec::SoloRunner.new(platform: 'ubuntu', version: '12.04') do |node|
ChefSpec::ServerRunner.new(platform: 'ubuntu', version: '12.04') do |node|
node.set['rsyslog']['use_relp'] = true
end.converge(described_recipe)
end
......@@ -26,7 +26,7 @@ describe 'rsyslog::default' do
context "when node['rsyslog']['enable_tls'] is true" do
context "when node['rsyslog']['tls_ca_file'] is not set" do
let(:chef_run) do
ChefSpec::SoloRunner.new(platform: 'ubuntu', version: '12.04') do |node|
ChefSpec::ServerRunner.new(platform: 'ubuntu', version: '12.04') do |node|
node.set['rsyslog']['enable_tls'] = true
end.converge(described_recipe)
end
......@@ -38,7 +38,7 @@ describe 'rsyslog::default' do
context "when node['rsyslog']['tls_ca_file'] is set" do
let(:chef_run) do
ChefSpec::SoloRunner.new(platform: 'ubuntu', version: '12.04') do |node|
ChefSpec::ServerRunner.new(platform: 'ubuntu', version: '12.04') do |node|
node.set['rsyslog']['enable_tls'] = true
node.set['rsyslog']['tls_ca_file'] = '/etc/path/to/ssl-ca.crt'
end.converge(described_recipe)
......@@ -55,7 +55,7 @@ describe 'rsyslog::default' do
end
let(:chef_run) do
ChefSpec::SoloRunner.new(platform: 'ubuntu', version: '12.04') do |node|
ChefSpec::ServerRunner.new(platform: 'ubuntu', version: '12.04') do |node|
node.set['rsyslog']['enable_tls'] = true
node.set['rsyslog']['tls_ca_file'] = '/etc/path/to/ssl-ca.crt'
node.set['rsyslog']['protocol'] = 'udp'
......@@ -87,7 +87,7 @@ describe 'rsyslog::default' do
context 'on SmartOS' do
let(:chef_run) do
ChefSpec::SoloRunner.new(platform: 'smartos', version: 'joyent_20130111T180733Z').converge(described_recipe)
ChefSpec::ServerRunner.new(platform: 'smartos', version: 'joyent_20130111T180733Z').converge(described_recipe)
end
let(:directory) { chef_run.directory('/opt/local/etc/rsyslog.d') }
......@@ -153,7 +153,7 @@ describe 'rsyslog::default' do
context 'on SmartOS' do
let(:chef_run) do
ChefSpec::SoloRunner.new(platform: 'smartos', version: 'joyent_20130111T180733Z').converge(described_recipe)
ChefSpec::ServerRunner.new(platform: 'smartos', version: 'joyent_20130111T180733Z').converge(described_recipe)
end
let(:template) { chef_run.template('/opt/local/etc/rsyslog.conf') }
......@@ -206,7 +206,7 @@ describe 'rsyslog::default' do
context 'on SmartOS' do
let(:chef_run) do
ChefSpec::SoloRunner.new(platform: 'smartos', version: 'joyent_20130111T180733Z').converge(described_recipe)
ChefSpec::ServerRunner.new(platform: 'smartos', version: 'joyent_20130111T180733Z').converge(described_recipe)
end
let(:template) { chef_run.template('/opt/local/etc/rsyslog.d/50-default.conf') }
......@@ -236,7 +236,7 @@ describe 'rsyslog::default' do
context 'COOK-3608 maillog regression test' do
let(:chef_run) do
ChefSpec::SoloRunner.new(platform: 'redhat', version: '6.3').converge(described_recipe)
ChefSpec::ServerRunner.new(platform: 'redhat', version: '6.3').converge(described_recipe)
end
it 'outputs mail.* to /var/log/maillog' do
......@@ -246,7 +246,7 @@ describe 'rsyslog::default' do
context 'syslog service' do
let(:chef_run) do
ChefSpec::SoloRunner.new(platform: 'redhat', version: '5.8').converge(described_recipe)
ChefSpec::ServerRunner.new(platform: 'redhat', version: '5.8').converge(described_recipe)
end
it 'stops and starts the syslog service on RHEL' do
......@@ -258,7 +258,7 @@ describe 'rsyslog::default' do
context 'system-log service' do
{ 'omnios' => '151002', 'smartos' => 'joyent_20130111T180733Z' }.each do |p, pv|
let(:chef_run) do
ChefSpec::SoloRunner.new(platform: p, version: pv).converge(described_recipe)
ChefSpec::ServerRunner.new(platform: p, version: pv).converge(described_recipe)
end
it "stops the system-log service on #{p}" do
......@@ -269,7 +269,7 @@ describe 'rsyslog::default' do
context 'on OmniOS' do
let(:chef_run) do
ChefSpec::SoloRunner.new(platform: 'omnios', version: '151002').converge(described_recipe)
ChefSpec::ServerRunner.new(platform: 'omnios', version: '151002').converge(described_recipe)
end
let(:template) { chef_run.template('/var/svc/manifest/system/rsyslogd.xml') }
......
......@@ -2,7 +2,7 @@ require 'spec_helper'
describe 'rsyslog::server' do
let(:chef_run) do
ChefSpec::SoloRunner.new(platform: 'ubuntu', version: '12.04') do |node|
ChefSpec::ServerRunner.new(platform: 'ubuntu', version: '12.04') do |node|
node.set['rsyslog']['server'] = false
end.converge(described_recipe)
end
......@@ -56,7 +56,7 @@ describe 'rsyslog::server' do
context 'on SmartOS' do
let(:chef_run) do
ChefSpec::SoloRunner.new(platform: 'smartos', version: 'joyent_20130111T180733Z') do |node|
ChefSpec::ServerRunner.new(platform: 'smartos', version: 'joyent_20130111T180733Z') do |node|
node.set['rsyslog']['server'] = false
end.converge(described_recipe)
end
......@@ -103,7 +103,7 @@ describe 'rsyslog::server' do
end
let(:chef_run) do
ChefSpec::SoloRunner.new(platform: 'smartos', version: 'joyent_20130111T180733Z') do |node|
ChefSpec::ServerRunner.new(platform: 'smartos', version: 'joyent_20130111T180733Z') do |node|
node.set['rsyslog']['server'] = false
end.converge(described_recipe)
end
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment