Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

More improvements #8

Merged
merged 23 commits into from
Dec 2, 2015
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Use install puppet helper for acceptance tests
  • Loading branch information
vladgh committed Dec 2, 2015
commit 60b27de84639d218ad934d3ca4609bbc90f35fdb
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ HOSTS:
docker_container_name: ubuntu-trusty-x64
docker_preserve_image: true
docker_image_commands:
- 'locale-gen en_US.UTF-8 && wget -O /tmp/puppetlabs-release.deb https://apt.puppetlabs.com/puppetlabs-release-pc1-$(lsb_release -cs).deb && dpkg -i /tmp/puppetlabs-release.deb && apt-get update && apt-get -y install puppet-agent'
- 'locale-gen en_US.UTF-8'

CONFIG:
type: aio
Expand Down
9 changes: 7 additions & 2 deletions dist/profile/spec/spec_helper_acceptance.rb
Original file line number Diff line number Diff line change
@@ -1,11 +1,15 @@
require 'beaker-rspec/spec_helper'
require 'beaker-rspec/helpers/serverspec'
require 'beaker/puppet_install_helper'

# Install Puppet
run_puppet_install_helper unless ENV['BEAKER_provision'] == 'no'

RSpec.configure do |c|
proj_root = File.expand_path(File.join(File.dirname(__FILE__), '..'))
modules_dir = File.join(proj_root, 'spec', 'fixtures', 'modules')
hiera_dir = File.join(proj_root, 'spec', 'fixtures', 'hieradata')
host_hiera_dir = '/etc/puppetlabs/code/environments/production'
hiera_host_dir = '/etc/puppetlabs/code/environments/production'

# Readable test descriptions
c.formatter = :documentation
Expand All @@ -30,7 +34,8 @@
# transferred in the step above
copy_module_to host, source: proj_root, module_name: 'profile'

scp_to host, hiera_dir, host_hiera_dir
shell "mkdir -p #{hiera_host_dir}"
scp_to host, hiera_dir, hiera_host_dir
end
end
end