From 153b27bef2cc146465938a7a168da5ebe439c9f8 Mon Sep 17 00:00:00 2001 From: Hunter Haugen Date: Thu, 11 Jun 2015 15:41:17 -0700 Subject: Add helper to install puppet/pe/puppet-agent --- spec/spec_helper_acceptance.rb | 25 ++----------------------- 1 file changed, 2 insertions(+), 23 deletions(-) (limited to 'spec') diff --git a/spec/spec_helper_acceptance.rb b/spec/spec_helper_acceptance.rb index 78074f7..97c43e8 100644 --- a/spec/spec_helper_acceptance.rb +++ b/spec/spec_helper_acceptance.rb @@ -1,28 +1,7 @@ require 'beaker-rspec' +require 'beaker/puppet_install_helper' -unless ENV['RS_PROVISION'] == 'no' or ENV['BEAKER_provision'] == 'no' - # This will install the latest available package on el and deb based - # systems fail on windows and osx, and install via gem on other *nixes - foss_opts = { - :default_action => 'gem_install', - :version => (ENV['PUPPET_VERSION'] || '3.8.1'), - } - - if default.is_pe?; then install_pe; else install_puppet( foss_opts ); end - - hosts.each do |host| - unless host.is_pe? - on hosts, "mkdir -p #{hosts.first['distmoduledir']}" - end - - # We ask the host to interpolate it's distmoduledir because we don't - # actually know it on Windows until we've let it redirect us (depending - # on whether we're running as a 32/64 bit process on 32/64 bit Windows - moduledir = on(host, "echo #{host['distmoduledir']}").stdout.chomp - on host, "mkdir -p #{moduledir}" - end -end - +run_puppet_install_helper RSpec.configure do |c| # Project root -- cgit v1.2.3