]> gitweb.fluxo.info Git - puppet-ferm.git/commitdiff
modulesync 2.0.0
authorTim Meusel <tim@bastelfreak.de>
Thu, 4 Oct 2018 21:37:34 +0000 (23:37 +0200)
committerTim Meusel <tim@bastelfreak.de>
Thu, 4 Oct 2018 21:40:17 +0000 (23:40 +0200)
.github/CONTRIBUTING.md
.msync.yml
.travis.yml
Gemfile

index 496a5c0347cc3a2c01f1ec49e63ac83493497a53..67b063cd0472b71b480b645896c233073725f59b 100644 (file)
@@ -12,15 +12,19 @@ By participating in this project you agree to abide by its terms.
 
 1. Create a separate branch for your change.
 
-1. Run the tests. We only take pull requests with passing tests, and
-   documentation.
+1. We only take pull requests with passing tests, and documentation. [travis-ci](http://travis-ci.org)
+   runs the tests for us. You can also execute them locally. This is explained
+   in a later section.
+
+1. Checkout the docs we use to review a module. They provide some guidance for
+   new code that might help you before you submit a pull request.
 
 1. Add a test for your change. Only refactoring and documentation
    changes require no new tests. If you are adding functionality
    or fixing a bug, please add a test.
 
 1. Squash your commits down into logical components. Make sure to rebase
-   against the current master.
+   against our current master.
 
 1. Push the branch to your fork and submit a pull request.
 
@@ -38,7 +42,9 @@ By default the tests use a baseline version of Puppet.
 If you have Ruby 2.x or want a specific version of Puppet,
 you must set an environment variable such as:
 
-    export PUPPET_VERSION="~> 4.2.0"
+```sh
+export PUPPET_VERSION="~> 5.5.6"
+```
 
 You can install all needed gems for spec tests into the modules directory by
 running:
@@ -65,13 +71,17 @@ The test suite will run [Puppet Lint](http://puppet-lint.com/) and
 [Puppet Syntax](https://github.com/gds-operations/puppet-syntax) to
 check various syntax and style things. You can run these locally with:
 
-    bundle exec rake lint
-    bundle exec rake validate
+```sh
+bundle exec rake lint
+bundle exec rake validate
+```
 
 It will also run some [Rubocop](http://batsov.com/rubocop/) tests
 against it. You can run those locally ahead of time with:
 
-    bundle exec rake rubocop
+```sh
+bundle exec rake rubocop
+```
 
 ## Running the unit tests
 
@@ -82,15 +92,21 @@ about how best to test your new feature.
 
 To run the linter, the syntax checker and the unit tests:
 
-    bundle exec rake test
+```sh
+bundle exec rake test
+```
 
 To run your all the unit tests
 
-    bundle exec rake spec SPEC_OPTS='--format documentation'
+```sh
+bundle exec rake spec
+```
 
 To run a specific spec test set the `SPEC` variable:
 
-    bundle exec rake spec SPEC=spec/foo_spec.rb
+```sh
+bundle exec rake spec SPEC=spec/foo_spec.rb
+```
 
 ## Integration tests
 
@@ -102,23 +118,51 @@ This fires up a new virtual machine (using vagrant) and runs a series of
 simple tests against it after applying the module. You can run this
 with:
 
-    bundle exec rake acceptance
+```sh
+bundle exec rake acceptance
+```
 
 This will run the tests on the module's default nodeset. You can override the
 nodeset used, e.g.,
 
-    BEAKER_set=centos-7-x64 bundle exec rake acceptance
+```sh
+BEAKER_set=centos-7-x64 bundle exec rake acceptance
+```
 
 There are default rake tasks for the various acceptance test modules, e.g.,
 
-    bundle exec rake beaker:centos-7-x64
-    bundle exec rake beaker:ssh:centos-7-x64
+```sh
+bundle exec rake beaker:centos-7-x64
+bundle exec rake beaker:ssh:centos-7-x64
+```
 
 If you don't want to have to recreate the virtual machine every time you can
 use `BEAKER_destroy=no` and `BEAKER_provision=no`. On the first run you will at
 least need `BEAKER_provision` set to yes (the default). The Vagrantfile for the
 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:
+
+```
+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
+```
+
+You can replace the string `debian9` with any common operating system.
+The following strings are known to work:
+
+* ubuntu1604
+* ubuntu1804
+* debian8
+* debian9
+* centos6
+* centos7
+
 The easiest way to debug in a docker container is to open a shell:
 
-    docker exec -it -u root ${container_id_or_name} bash
+```sh
+docker exec -it -u root ${container_id_or_name} bash
+```
+
+The source of this file is in our [modulesync_config](https://github.com/voxpupuli/modulesync_config/blob/master/moduleroot/.github/CONTRIBUTING.md.erb)
+repository.
index e1cef550d5b7d96451d797ea4674c3bfbe9ad3f7..45b7d7c22ef67c89da0f9d5df7c27c64c26c25f1 100644 (file)
@@ -1 +1 @@
-modulesync_config_version: '2.0.0'
+modulesync_config_version: '2.0.0-rc0'
index 2407a6f0a65e40cb44d6e6bf740086ba390bb0ab..99e0c446066aa1334dd98aa643862253c1f3895d 100644 (file)
@@ -18,11 +18,11 @@ matrix:
     env: PUPPET_VERSION="~> 5.0" CHECK=test
   - rvm: 2.5.1
     bundler_args: --without system_tests development release
-    env: PUPPET_VERSION="~> 5.0" CHECK=test_with_coveralls
-  - rvm: 2.4.4
-    bundler_args: --without system_tests development release
-    env: PUPPET_VERSION="~> 5.0" CHECK=rubocop
+    env: PUPPET_VERSION="~> 6.0" CHECK=test_with_coveralls
   - rvm: 2.5.1
+    bundler_args: --without system_tests development release
+    env: PUPPET_VERSION="~> 6.0" CHECK=rubocop
+  - rvm: 2.4.4
     bundler_args: --without system_tests development release
     env: PUPPET_VERSION="~> 5.0" CHECK=build DEPLOY_TO_FORGE=yes
 branches:
diff --git a/Gemfile b/Gemfile
index 20f3df025b20fbce7cf7c436967772d9127747a6..7e14df4eb96e234e5d3840d9f3ad1f421ebc92c9 100644 (file)
--- a/Gemfile
+++ b/Gemfile
@@ -11,8 +11,7 @@ def location_for(place, fake_version = nil)
 end
 
 group :test do
-  gem 'puppetlabs_spec_helper', '~> 2.6',                           :require => false
-  gem 'rspec-puppet', '~> 2.5',                                     :require => false
+  gem 'puppetlabs_spec_helper', '~> 2.11.0',                        :require => false
   gem 'rspec-puppet-facts',                                         :require => false
   gem 'rspec-puppet-utils',                                         :require => false
   gem 'puppet-lint-leading_zero-check',                             :require => false