]> gitweb.fluxo.info Git - puppet-stdlib.git/commitdiff
Use puppet_install_helper
authorMorgan Haskel <morgan@puppetlabs.com>
Fri, 10 Jul 2015 00:11:10 +0000 (17:11 -0700)
committerMorgan Haskel <morgan@puppetlabs.com>
Fri, 10 Jul 2015 00:11:10 +0000 (17:11 -0700)
Gemfile
spec/spec_helper_acceptance.rb

diff --git a/Gemfile b/Gemfile
index 64c906632d7b43138bce97ae185c2e4da7b0d960..fbb9a25605096f5645a152d3d87741951f7ec00c 100644 (file)
--- a/Gemfile
+++ b/Gemfile
@@ -32,9 +32,10 @@ group :system_tests do
   if beaker_rspec_version
     gem 'beaker-rspec', *location_for(beaker_rspec_version)
   else
-    gem 'beaker-rspec',  :require => false
+    gem 'beaker-rspec', :require => false
   end
-  gem 'serverspec',    :require => false
+  gem 'serverspec', :require => false
+  gem 'beaker-puppet_install_helper', :require => false
 end
 
 facterversion = ENV['GEM_FACTER_VERSION'] || ENV['FACTER_GEM_VERSION']
index 39d2d52e072cee4f75485d135fe077734c060013..7b09a38c2edb8bd82acfc5aba09031973b434a04 100755 (executable)
@@ -1,28 +1,10 @@
 #! /usr/bin/env ruby -S rspec
 require 'beaker-rspec'
+require 'beaker/puppet_install_helper'
 
 UNSUPPORTED_PLATFORMS = []
 
-unless ENV['RS_PROVISION'] == 'no' or ENV['BEAKER_provision'] == 'no'
-  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|
-    if host['platform'] !~ /windows/i
-      if host.is_pe?
-        on host, 'mkdir -p /etc/puppetlabs/facter/facts.d'
-      else
-        on host, "/bin/touch #{host['puppetpath']}/hiera.yaml"
-        on host, "mkdir -p #{host['distmoduledir']}"
-        on host, 'mkdir -p /etc/facter/facts.d'
-      end
-    end
-  end
-end
+run_puppet_install_helper
 
 RSpec.configure do |c|
   # Project root