]> review.fuel-infra Code Review - puppet-modules/puppetlabs-firewall.git/commitdiff
Support rspec-puppet v1.0.0
authorGarrett Honeycutt <code@garretthoneycutt.com>
Fri, 27 Dec 2013 22:39:21 +0000 (17:39 -0500)
committerGarrett Honeycutt <code@garretthoneycutt.com>
Fri, 27 Dec 2013 22:39:21 +0000 (17:39 -0500)
include_class has been replaced with contain_class.
http://bombasticmonkey.com/2013/12/05/rspec-puppet-1.0.0/

spec/unit/classes/firewall_spec.rb

index 87c3f2b8f4530bbc386307b6ce8f7e5eee5d5a3b..efc153ab2e424ae2996e5487ddd0e4fbcba957a4 100644 (file)
@@ -8,7 +8,7 @@ describe 'firewall', :type => :class do
 
   context 'kernel => Windows' do
     let(:facts) {{ :kernel => 'Windows' }}
-    it { expect { should include_class('firewall::linux') }.to raise_error(Puppet::Error) }
+    it { expect { should contain_class('firewall::linux') }.to raise_error(Puppet::Error) }
   end
 
   context 'ensure => stopped' do
@@ -20,6 +20,6 @@ describe 'firewall', :type => :class do
   context 'ensure => test' do
     let(:facts) {{ :kernel => 'Linux' }}
     let(:params) {{ :ensure => 'test' }}
-    it { expect { should include_class('firewall::linux') }.to raise_error(Puppet::Error) }
+    it { expect { should contain_class('firewall::linux') }.to raise_error(Puppet::Error) }
   end
 end