2 describe 'apt::params', :type => :class do
3 let(:facts) { { :lsbdistid => 'Debian', :osfamily => 'Debian' } }
4 let (:title) { 'my_package' }
6 it { should contain_apt__params }
8 # There are 4 resources in this class currently
9 # there should not be any more resources because it is a params class
10 # The resources are class[apt::params], class[main], class[settings], stage[main]
11 it "Should not contain any resources" do
12 subject.resources.size.should == 4
15 describe "With unknown lsbdistid" do
17 let(:facts) { { :lsbdistid => 'CentOS' } }
18 let (:title) { 'my_package' }
23 }.to raise_error(Puppet::Error, /Unsupported lsbdistid/)
28 describe "With lsb-release not installed" do
29 let(:facts) { { :lsbdistid => '' } }
30 let (:title) { 'my_package' }
35 }.to raise_error(Puppet::Error, /Unable to determine lsbdistid, is lsb-release installed/)