diff --git a/.github/CONTRIBUTING.md b/.github/CONTRIBUTING.md index 5d047472..38cacd4e 100644 --- a/.github/CONTRIBUTING.md +++ b/.github/CONTRIBUTING.md @@ -51,19 +51,34 @@ You can install all needed gems for spec tests into the modules directory by running: ```sh -bundle install --path .vendor/ --without development system_tests release +bundle install --path .vendor/ --without development system_tests release --jobs "$(nproc)" ``` If you also want to run acceptance tests: ```sh -bundle install --path .vendor/ --with system_tests --without development release +bundle install --path .vendor/ --with system_tests --without development release --jobs "$(nproc)" ``` Our all in one solution if you don't know if you need to install or update gems: ```sh -bundle install --path .vendor/ --with system_tests --without development release; bundle update; bundle clean +bundle install --path .vendor/ --with system_tests --without development release --jobs "$(nproc)"; bundle update; bundle clean +``` + +As an alternative to the `--jobs "$(nproc)` parameter, you can set an +environment variable: + +```sh +BUNDLE_JOBS="$(nproc)" +``` + +### Note for OS X users + +`nproc` isn't a valid command unter OS x. As an alternative, you can do: + +```sh +--jobs "$(sysctl -n hw.ncpu)" ``` ## Syntax and style @@ -160,7 +175,7 @@ created virtual machines will be in `.vagrant/beaker_vagrant_files`. Beaker also supports docker containers. We also use that in our automated CI pipeline at [travis-ci](http://travis-ci.org). To use that instead of Vagrant: -``` +```sh PUPPET_INSTALL_TYPE=agent BEAKER_IS_PE=no BEAKER_PUPPET_COLLECTION=puppet5 BEAKER_debug=true BEAKER_setfile=debian9-64{hypervisor=docker} BEAKER_destroy=yes bundle exec rake beaker ``` diff --git a/.msync.yml b/.msync.yml index 55198916..23dfa32f 100644 --- a/.msync.yml +++ b/.msync.yml @@ -1 +1 @@ -modulesync_config_version: '2.7.0' +modulesync_config_version: '2.8.0' diff --git a/Gemfile b/Gemfile index 24dbb7ff..9571ef3c 100644 --- a/Gemfile +++ b/Gemfile @@ -21,6 +21,7 @@ group :test do gem 'puppet-lint-unquoted_string-check', :require => false gem 'puppet-lint-variable_contains_upcase', :require => false gem 'puppet-lint-absolute_classname-check', :require => false + gem 'puppet-lint-topscope-variable-check', :require => false gem 'metadata-json-lint', :require => false gem 'redcarpet', :require => false gem 'rubocop', '~> 0.49.1', :require => false diff --git a/spec/spec_helper.rb b/spec/spec_helper.rb index 0fdeac9e..b815a83b 100644 --- a/spec/spec_helper.rb +++ b/spec/spec_helper.rb @@ -7,6 +7,7 @@ require 'puppetlabs_spec_helper/module_spec_helper' require 'rspec-puppet-facts' +require 'bundler' include RspecPuppetFacts if File.exist?(File.join(__dir__, 'default_module_facts.yml')) @@ -31,6 +32,7 @@ add_filter '/spec' add_filter '/vendor' add_filter '/.vendor' + add_filter Bundler.configured_bundle_path.path end end