forked from redhat-openstack/openstack-puppet-modules
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add rspec test to ensure the bracket syntax is using when available
- Loading branch information
txaj
committed
Dec 11, 2014
1 parent
5ef3917
commit 3f33f0d
Showing
1 changed file
with
34 additions
and
0 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 |
---|---|---|
@@ -0,0 +1,34 @@ | ||
require 'spec_helper' | ||
|
||
describe 'collectd::plugin', :type => :define do | ||
|
||
context 'loading a plugin on collectd <= 4.9.4' do | ||
let(:title) { 'test' } | ||
let :facts do | ||
{ | ||
:collectd_version => '5.3', | ||
:osfamily => 'Debian', | ||
} | ||
end | ||
|
||
it 'Will create /etc/collectd/conf.d/10-test.conf with the LoadPlugin syntax with brackets' do | ||
should contain_file('test.load').with_content(/<LoadPlugin/) | ||
end | ||
end | ||
|
||
|
||
context 'loading a plugin on collectd => 4.9.3' do | ||
let(:title) { 'test' } | ||
let :facts do | ||
{ | ||
:collectd_version => '4.9.3', | ||
:osfamily => 'Debian', | ||
} | ||
end | ||
|
||
it 'Will create /etc/collectd/conf.d/10-test.conf with the LoadPlugin syntax without brackets' do | ||
should contain_file('test.load').without_content(/<LoadPlugin/) | ||
end | ||
end | ||
|
||
end |