X-Git-Url: https://review.fuel-infra.org/gitweb?a=blobdiff_plain;f=spec%2Fclasses%2Fapt_backports_spec.rb;h=f2172d92a99396031c349062a70725e4eed2cbea;hb=e014fc04ed8358e4f7c2e87f7434df9817a4c7bb;hp=c0d54a21c990e5e2f18d4e7326ad45254b6a472a;hpb=df40baebedf5c0c15e08f3ec78adfd760b1371ca;p=puppet-modules%2Fpuppetlabs-apt.git diff --git a/spec/classes/apt_backports_spec.rb b/spec/classes/apt_backports_spec.rb index c0d54a2..f2172d9 100644 --- a/spec/classes/apt_backports_spec.rb +++ b/spec/classes/apt_backports_spec.rb @@ -15,7 +15,7 @@ describe 'apt::backports', :type => :class do } end it { is_expected.to contain_apt__source('backports').with({ - :location => 'http://httpredir.debian.org/debian', + :location => 'http://deb.debian.org/debian', :key => 'A1BD8E9D78F7FE5C3E65D8AF8B48AD6246925553', :repos => 'main contrib non-free', :release => 'wheezy-backports', @@ -23,25 +23,6 @@ describe 'apt::backports', :type => :class do }) } end - context 'defaults on squeeze' do - let(:facts) do - { - :os => { :family => 'Debian', :name => 'Debian', :release => { :major => '6', :full => '6.0' }}, - :lsbdistid => 'Debian', - :osfamily => 'Debian', - :lsbdistcodename => 'squeeze', - :puppetversion => Puppet.version, - } - end - it { is_expected.to contain_apt__source('backports').with({ - :location => 'http://httpredir.debian.org/debian-backports', - :key => 'A1BD8E9D78F7FE5C3E65D8AF8B48AD6246925553', - :repos => 'main contrib non-free', - :release => 'squeeze-backports', - :pin => { 'priority' => 200, 'release' => 'squeeze-backports' }, - }) - } - end context 'defaults on ubuntu' do let(:facts) do { @@ -224,7 +205,7 @@ describe 'apt::backports', :type => :class do it do expect { subject.call - }.to raise_error(Puppet::Error, /expects a String value/) + }.to raise_error(Puppet::Error, /expects a/) end end context 'invalid release' do @@ -236,7 +217,7 @@ describe 'apt::backports', :type => :class do it do expect { subject.call - }.to raise_error(Puppet::Error, /expects a String value/) + }.to raise_error(Puppet::Error, /expects a/) end end context 'invalid repos' do @@ -248,7 +229,7 @@ describe 'apt::backports', :type => :class do it do expect { subject.call - }.to raise_error(Puppet::Error, /expects a String value/) + }.to raise_error(Puppet::Error, /expects a/) end end context 'invalid key' do @@ -260,7 +241,7 @@ describe 'apt::backports', :type => :class do it do expect { subject.call - }.to raise_error(Puppet::Error, /expects a value of type String or Hash, got Boolean/) + }.to raise_error(Puppet::Error, /expects a/) end end context 'invalid pin' do @@ -272,7 +253,7 @@ describe 'apt::backports', :type => :class do it do expect { subject.call - }.to raise_error(Puppet::Error, /expects a value of type Integer, String, or Hash, got Boolean/) + }.to raise_error(Puppet::Error, /expects a/) end end end