-
Notifications
You must be signed in to change notification settings - Fork 12
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Updated config files to match the latest packages
- Loading branch information
Showing
8 changed files
with
92 additions
and
17 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,6 @@ | ||
language: ruby | ||
|
||
rvm: | ||
- 1.9.3 | ||
- 2.0.0 | ||
- 2.1.0 | ||
|
||
before_script: | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
require 'spec_helper' | ||
|
||
describe 'beanstalkd::default' do | ||
let(:chef_run) do | ||
ChefSpec::ServerRunner.new(:platform => 'debian', :version => '7.2') do |node| | ||
node.automatic[:fqdn] = 'myserver' | ||
end.converge(described_recipe) | ||
end | ||
|
||
it 'should install beanstalkd service' do | ||
expect(chef_run).to upgrade_package('beanstalkd') | ||
end | ||
|
||
it 'should start beanstalkd service' do | ||
expect(chef_run).to enable_service('beanstalkd') | ||
expect(chef_run).to start_service('beanstalkd') | ||
end | ||
|
||
it 'should creates a defaults file at /etc/default/beanstalkd' do | ||
expect(chef_run).to(render_file('/etc/default/beanstalkd').with_content do |content| | ||
expect(content).to include('Generated by Chef for myserver') | ||
expect(content).to include('DAEMON_OPTS="-p 11300 -l 127.0.0.1 "') | ||
end) | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,26 @@ | ||
require 'spec_helper' | ||
|
||
describe 'beanstalkd::default' do | ||
let(:chef_run) { ChefSpec::Runner.new.converge(described_recipe) } | ||
let(:chef_run) do | ||
ChefSpec::ServerRunner.new(:platform_family => 'centos') do |node| | ||
node.automatic[:fqdn] = 'myserver' | ||
end.converge(described_recipe) | ||
end | ||
|
||
it 'should install beanstalkd service' do | ||
expect(chef_run).to upgrade_package('beanstalkd') | ||
end | ||
|
||
it 'should start beanstalkd service' do | ||
expect(chef_run).to enable_service('beanstalkd') | ||
expect(chef_run).to start_service('beanstalkd') | ||
end | ||
|
||
it 'should creates a defaults file at /etc/sysconfig/beanstalkd' do | ||
expect(chef_run).to(render_file('/etc/sysconfig/beanstalkd').with_content do |content| | ||
expect(content).to include('Generated by Chef for myserver') | ||
expect(content).to include('BEANSTALKD_ADDR=127.0.0.1') | ||
expect(content).to include('BEANSTALKD_PORT=11300') | ||
end) | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,27 @@ | ||
require 'spec_helper' | ||
|
||
describe 'beanstalkd::default' do | ||
let(:chef_run) do | ||
ChefSpec::ServerRunner.new(:platform => 'ubuntu', :version => '14.04') do |node| | ||
node.automatic[:fqdn] = 'myserver' | ||
end.converge(described_recipe) | ||
end | ||
|
||
it 'should install beanstalkd service' do | ||
expect(chef_run).to upgrade_package('beanstalkd') | ||
end | ||
|
||
it 'should start beanstalkd service' do | ||
expect(chef_run).to enable_service('beanstalkd') | ||
expect(chef_run).to start_service('beanstalkd') | ||
end | ||
|
||
it 'should creates a defaults file at /etc/default/beanstalkd' do | ||
expect(chef_run).to(render_file('/etc/default/beanstalkd').with_content do |content| | ||
expect(content).to include('Generated by Chef for myserver') | ||
expect(content).to include('BEANSTALKD_LISTEN_ADDR=127.0.0.1') | ||
expect(content).to include('BEANSTALKD_LISTEN_PORT=11300') | ||
expect(content).to include('BEANSTALKD_EXTRA=""') | ||
end) | ||
end | ||
end |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters