diff --git a/.sync.yml b/.sync.yml index 749e362..1e3d149 100644 --- a/.sync.yml +++ b/.sync.yml @@ -1,3 +1,5 @@ --- .travis.yml: secure: "Wb5Hs28JNnFp4ZuQp4KTzUDfT3hXK5QW50e25gFULXjIY1+/vmhxb43Wl27lL+8/vRRe+1t3z0AIrZiYYapQWgWGfvAaBux1tRVTprWme4YqURMNSW4bxXVtYpCA4O0HiTJq6WZoRT9+/LRmEPnyBHSackgYKF0R4/LnZGfK0AY=" +spec/spec_helper_acceptance.rb: + managed: true diff --git a/Gemfile b/Gemfile index 11c8558..32c3114 100644 --- a/Gemfile +++ b/Gemfile @@ -24,27 +24,7 @@ group :development do end group :system_tests do - gem 'winrm', :require => false - if beaker_version = ENV['BEAKER_VERSION'] - gem 'beaker', *location_for(beaker_version) - else - gem 'beaker', '>= 4.2.0', :require => false - end - if beaker_rspec_version = ENV['BEAKER_RSPEC_VERSION'] - gem 'beaker-rspec', *location_for(beaker_rspec_version) - else - gem 'beaker-rspec', :require => false - end - gem 'serverspec', :require => false - gem 'beaker-hostgenerator', '>= 1.1.22', :require => false - gem 'beaker-docker', :require => false - gem 'beaker-puppet', :require => false - gem 'beaker-puppet_install_helper', :require => false - gem 'beaker-module_install_helper', :require => false - gem 'rbnacl', '>= 4', :require => false - gem 'rbnacl-libsodium', :require => false - gem 'bcrypt_pbkdf', :require => false - gem 'ed25519', :require => false + gem 'voxpupuli-acceptance', :require => false end group :release do diff --git a/spec/spec_helper_acceptance.rb b/spec/spec_helper_acceptance.rb index 2afe009..69d431c 100644 --- a/spec/spec_helper_acceptance.rb +++ b/spec/spec_helper_acceptance.rb @@ -1,47 +1,3 @@ -require 'puppet' -require 'beaker-rspec/spec_helper' -require 'beaker-rspec/helpers/serverspec' +require 'voxpupuli/test/spec_helper_acceptance' -# overriding puppet installation for the RedHat family distros due to -# puppet breakage >= 3.5 -def install_puppet(host) - host['platform'] =~ %r{(fedora|el)-(\d+)} - if host['platform'] =~ %r{(fedora|el)-(\d+)} - safeversion = '3.4.2' - platform = Regexp.last_match(1) - relver = Regexp.last_match(2) - on host, "rpm -ivh http://yum.puppetlabs.com/puppetlabs-release-#{platform}-#{relver}.noarch.rpm" - on host, "yum install -y puppet-#{safeversion}" - else - super() - end -end - -RSpec.configure do |c| - # Project root - proj_root = File.expand_path(File.join(File.dirname(__FILE__), '..')) - - c.before(:each) do - Puppet::Util::Log.level = :warning - Puppet::Util::Log.newdestination(:console) - end - - c.before :suite do - hosts.each do |host| - unless ENV['RS_PROVISION'] == 'no' || ENV['BEAKER_provision'] == 'no' - begin - on host, 'puppet --version' - rescue - if host.is_pe? - install_pe - else - install_puppet(host) - end - end - end - - # Install module and dependencies - puppet_module_install(source: proj_root, module_name: File.basename(proj_root).gsub(%r{^puppet-}, '')) - end - end -end +configure_beaker