From: David Schmitt Date: Mon, 25 Jan 2016 14:05:57 +0000 (+0000) Subject: (FM-4049) Update to current msync configs [02da671] X-Git-Url: https://review.fuel-infra.org/gitweb?a=commitdiff_plain;h=refs%2Fheads%2Ffm-4049-update-msync;p=puppet-modules%2Fpuppetlabs-apt.git (FM-4049) Update to current msync configs [02da671] --- diff --git a/.gitignore b/.gitignore index b5db85e..3190277 100644 --- a/.gitignore +++ b/.gitignore @@ -5,5 +5,6 @@ spec/fixtures/ .vagrant/ .bundle/ coverage/ +log/ .idea/ *.iml diff --git a/.rspec b/.rspec new file mode 100644 index 0000000..16f9cdb --- /dev/null +++ b/.rspec @@ -0,0 +1,2 @@ +--color +--format documentation diff --git a/.travis.yml b/.travis.yml index 8b6adc2..c5688fa 100644 --- a/.travis.yml +++ b/.travis.yml @@ -1,8 +1,9 @@ --- 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: diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index f1cbde4..bfeaa70 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -159,7 +159,7 @@ If you already have those gems installed, make sure they are up-to-date: 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 @@ -178,8 +178,8 @@ installed on your system. 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), diff --git a/Gemfile b/Gemfile index 643d3f5..391162e 100644 --- a/Gemfile +++ b/Gemfile @@ -1,7 +1,7 @@ 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 }] @@ -18,7 +18,6 @@ group :development, :unit_tests do 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) @@ -29,11 +28,8 @@ group :system_tests do 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 diff --git a/Rakefile b/Rakefile index 181157e..35ce311 100644 --- a/Rakefile +++ b/Rakefile @@ -1,5 +1,6 @@ -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') diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb index 2c6f566..a7f5b4e 100644 --- a/spec/spec_helper.rb +++ b/spec/spec_helper.rb @@ -1 +1,7 @@ require 'puppetlabs_spec_helper/module_spec_helper' + +# put local configuration and setup into spec_helper_local +begin + require 'spec_helper_local' +rescue LoadError +end