Skip to content

Commit

Permalink
Added extra tests to catch JSON configuration error.
Browse files Browse the repository at this point in the history
  • Loading branch information
jonathanio committed Jan 16, 2015
1 parent 5b7047d commit 4790352
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions spec/defines/sensu_extension_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@
:source => 'puppet:///somewhere/mycommand.rb'
} }
it { should contain_file('/etc/sensu/extensions/mycommand.rb').with_source('puppet:///somewhere/mycommand.rb')}
it { should contain_file('/etc/sensu/conf.d/extensions/myextension.json') }
it { should contain_sensu_extension('myextension').with(
:ensure => 'present',
:config => {}
Expand All @@ -21,6 +22,7 @@
:source => 'puppet:///somewhere/mycommand.rb'
} }
it { should contain_sensu_extension('myextension').with_ensure('absent') }
it { should contain_file('/etc/sensu/conf.d/extensions/myextension.json').with_ensure('absent') }
end

context 'install path' do
Expand Down

0 comments on commit 4790352

Please sign in to comment.