X-Git-Url: https://review.fuel-infra.org/gitweb?a=blobdiff_plain;f=spec%2Facceptance%2Fforce_spec.rb;h=a43902300d7c0c1067db5660ee82396186eda631;hb=4d0bf7cbab1fc9c9fd0ff174315e69262cfe5f68;hp=f7e374be3a29facf6da77e0f859cd732d0d5fcb7;hpb=c2f0ed219e23ccc3faaf2512082240102921e4a9;p=puppet-modules%2Fpuppetlabs-apt.git diff --git a/spec/acceptance/force_spec.rb b/spec/acceptance/force_spec.rb index f7e374b..a439023 100644 --- a/spec/acceptance/force_spec.rb +++ b/spec/acceptance/force_spec.rb @@ -1,6 +1,8 @@ require 'spec_helper_acceptance' -describe 'apt::force define' do +codename = fact('lsbdistcodename') + +describe 'apt::force define', :unless => UNSUPPORTED_PLATFORMS.include?(fact('osfamily')) do context 'defaults' do it 'should work with no errors' do pp = <<-EOS @@ -21,12 +23,12 @@ describe 'apt::force define' do it 'should work with no errors' do pp = <<-EOS include apt - apt::force { 'vim': release => 'precise' } + apt::force { 'vim': release => '#{codename}' } EOS shell('apt-get remove -y vim') apply_manifest(pp, :catch_failures => true) do |r| - expect(r.stdout).to match(/apt-get -y -t precise install vim/) + expect(r.stdout).to match(/apt-get -y -t #{codename} install vim/) end end @@ -57,7 +59,7 @@ describe 'apt::force define' do it 'should work with no errors' do pp = <<-EOS include apt - apt::force { 'tomcat7': timeout => '1' } + apt::force { 'vim': timeout => '1' } EOS shell('apt-get clean')