diff --git a/.fixtures.yml b/.fixtures.yml index 79dd29c..73665c2 100644 --- a/.fixtures.yml +++ b/.fixtures.yml @@ -7,6 +7,6 @@ fixtures: ref: "v1.0.2" apt: repo: "https://github.com/puppetlabs/puppetlabs-apt.git" - ref: "2.4.0" + ref: "4.1.0" symlinks: vmwaretools: "#{source_dir}" diff --git a/.travis.yml b/.travis.yml index 1f3872c..6a63c6c 100644 --- a/.travis.yml +++ b/.travis.yml @@ -14,14 +14,6 @@ script: "bundle exec rake validate && bundle exec rake lint && bundle exec rake matrix: fast_finish: true include: - - rvm: 1.8.7 - env: PUPPET_GEM_VERSION="~> 3.0" - - rvm: 1.9.3 - env: PUPPET_GEM_VERSION="~> 3.0" - - rvm: 2.0.0 - env: PUPPET_GEM_VERSION="~> 3.0" - - rvm: 2.0.0 - env: PUPPET_GEM_VERSION="~> 3.0" FUTURE_PARSER="yes" - rvm: 2.1.9 env: PUPPET_GEM_VERSION="~> 4.0" - rvm: 2.4.1 diff --git a/manifests/repo.pp b/manifests/repo.pp index 0e65571..c1742d3 100644 --- a/manifests/repo.pp +++ b/manifests/repo.pp @@ -219,12 +219,13 @@ include '::apt' apt::source { 'vmware-tools': - ensure => $ensure, - comment => "VMware Tools ${tools_version} - ${vmwaretools::params::baseurl_string} ${::lsbdistcodename}", - location => $baseurl_url, - key_source => $gpgkey, - #key => '0xC0B5E0AB66FD4949', - key => '36E47E1CC4DCC5E8152D115CC0B5E0AB66FD4949', + ensure => $ensure, + comment => "VMware Tools ${tools_version} - ${vmwaretools::params::baseurl_string} ${::lsbdistcodename}", + location => $baseurl_url, + key => { + source => $gpgkey, + id => '36E47E1CC4DCC5E8152D115CC0B5E0AB66FD4949', + } } } default: { } diff --git a/metadata.json b/metadata.json index 69798b1..d863cfd 100644 --- a/metadata.json +++ b/metadata.json @@ -19,7 +19,7 @@ }, { "name": "puppetlabs/apt", - "version_requirement": ">=2.0.0 <3.0.0" + "version_requirement": ">=3.0.0 <5.0.0" }, { "name": "wolfspyre/vmware_puppetfact", diff --git a/spec/classes/vmwaretools_init_spec.rb b/spec/classes/vmwaretools_init_spec.rb index 0813f6f..ecb232b 100644 --- a/spec/classes/vmwaretools_init_spec.rb +++ b/spec/classes/vmwaretools_init_spec.rb @@ -192,6 +192,13 @@ describe 'for osfamily Debian and operatingsystem Ubuntu' do let :facts do { + :os => { + :family => 'Debian', + :name => 'Ubuntu', + :release => { + :full => '12.04' + } + }, :virtual => 'vmware', :osfamily => 'Debian', :operatingsystem => 'Ubuntu', diff --git a/spec/classes/vmwaretools_repo_spec.rb b/spec/classes/vmwaretools_repo_spec.rb index c7ccd92..9a06dc1 100644 --- a/spec/classes/vmwaretools_repo_spec.rb +++ b/spec/classes/vmwaretools_repo_spec.rb @@ -30,6 +30,10 @@ describe "for osfamily #{osf} operatingsystem #{os}" do let(:params) {{}} let :facts do { + :os => { + :family => osf, + :name => os, + }, :osfamily => osf, :operatingsystem => os, :operatingsystemrelease => '1.0', @@ -54,6 +58,10 @@ redhatish.each do |os| describe "for operating system #{os}" do let :facts do { + :os => { + :family => 'RedHat', + :name => os, + }, :virtual => 'vmware', :osfamily => 'RedHat', :operatingsystemrelease => '6.1', @@ -82,6 +90,10 @@ suseish.each do |os| describe "for operating system #{os}" do let :facts do { + :os => { + :family => 'SuSE', + :name => os, + }, :virtual => 'vmware', :osfamily => 'SuSE', :operatingsystemrelease => '10', @@ -110,6 +122,13 @@ let(:pre_condition) { "class { 'apt': }" } let :facts do { :virtual => 'vmware', + :os => { + :family => 'Debian', + :name => 'Ubuntu', + :release => { + :full => '12.04' + } + }, :osfamily => 'Debian', :operatingsystemrelease => '12.04', :lsbmajdistrelease => '12', @@ -122,18 +141,26 @@ } end it { should contain_apt__source('vmware-tools').with( - :comment => 'VMware Tools latest - ubuntu precise', - :ensure => 'present', - :location => 'http://packages.vmware.com/tools/esx/latest/ubuntu', - :key_source => 'http://packages.vmware.com/tools/keys/VMWARE-PACKAGING-GPG-RSA-KEY.pub', - #:key => '0xC0B5E0AB66FD4949', - :key => '36E47E1CC4DCC5E8152D115CC0B5E0AB66FD4949' + :comment => 'VMware Tools latest - ubuntu precise', + :ensure => 'present', + :location => 'http://packages.vmware.com/tools/esx/latest/ubuntu', + :key => { + 'source' => 'http://packages.vmware.com/tools/keys/VMWARE-PACKAGING-GPG-RSA-KEY.pub', + 'id' => '36E47E1CC4DCC5E8152D115CC0B5E0AB66FD4949' + } )} end end context 'on a supported operatingsystem, vmware platform, custom parameters' do let :facts do { + :os => { + :family => 'RedHat', + :name => 'RedHat', + :release => { + :full => '6.1' + } + }, :virtual => 'vmware', :osfamily => 'RedHat', :operatingsystem => 'RedHat',