---
sudo: false
language: ruby
+cache: bundler
bundler_args: --without system_tests
-script: "bundle exec rake validate && bundle exec rake lint && bundle exec rake spec SPEC_OPTS='--format documentation'"
+script: "bundle exec rake validate lint spec"
matrix:
fast_finish: true
include:
With all dependencies in place and up-to-date we can now run the tests:
```shell
-% rake spec
+% bundle exec rake spec
```
This will execute all the [rspec tests](http://rspec-puppet.com/) tests
You can run them by issuing the following command
```shell
-% rake spec_clean
-% rspec spec/acceptance
+% bundle exec rake spec_clean
+% bundle exec rspec spec/acceptance
```
This will now download a pre-fabricated image configured in the [default node-set](./spec/acceptance/nodesets/default.yml),
source ENV['GEM_SOURCE'] || "https://rubygems.org"
def location_for(place, fake_version = nil)
- if place =~ /^(git:[^#]*)#(.*)/
+ if place =~ /^(git[:@][^#]*)#(.*)/
[fake_version, { :git => $1, :branch => $2, :require => false }].compact
elsif place =~ /^file:\/\/(.*)/
['>= 0', { :path => File.expand_path($1), :require => false }]
gem 'puppet_facts', :require => false
gem 'json', :require => false
end
-
group :system_tests do
if beaker_version = ENV['BEAKER_VERSION']
gem 'beaker', *location_for(beaker_version)
gem 'beaker-rspec', :require => false
end
gem 'serverspec', :require => false
- gem 'beaker-puppet_install_helper', :require => false
end
-
-
if facterversion = ENV['FACTER_GEM_VERSION']
gem 'facter', facterversion, :require => false
else
-require 'puppetlabs_spec_helper/rake_tasks'
+require 'puppet_blacksmith/rake_tasks'
require 'puppet-lint/tasks/puppet-lint'
+require 'puppetlabs_spec_helper/rake_tasks'
PuppetLint.configuration.fail_on_warnings = true
PuppetLint.configuration.send('relative')