Unverified Commit e1dec8c7 authored by Jonathan's avatar Jonathan Committed by GitHub
Browse files

Merge pull request #141 from SearchLightNZ/pdk_1.18.1

Update PDK to 1.18.1 and re-work tests
parents b40d0884 d2d902dc
Loading
Loading
Loading
Loading
+6 −7
Original line number Diff line number Diff line
fixtures:
    symlinks:
      freeradius: "#{source_dir}"
    repositories:
      stdlib:
        repo: https://github.com/puppetlabs/puppetlabs-stdlib.git
        ref: 4.3.2
  forge_modules:
    concat: "puppetlabs/concat"
    firewall: "puppetlabs/firewall"
    logrotate: "puppet/logrotate"
    rsyslog: "saz/rsyslog"
    stdlib: "puppetlabs/stdlib"
+8 −5
Original line number Diff line number Diff line
@@ -10,22 +10,25 @@ cache:
before_script:
  - bundle -v
  - rm Gemfile.lock || true
  - gem update --system $RUBYGEMS_VERSION
  - "# Update system gems if requested. This is useful to temporarily workaround troubles in the test runner"
  - "# Set `rubygems_version` in the .sync.yml to set a value"
  - "# Ignore exit code of SIGPIPE'd yes to not fail with shell's pipefail set"
  - '[ -z "$RUBYGEMS_VERSION" ] || (yes || true) | gem update --system $RUBYGEMS_VERSION'
  - gem --version
  - bundle -v
  - bundle install --without system_tests --path vendor/bundle --jobs $(nproc)

syntax lint metadata_lint check:symlinks check:git_ignore check:dot_underscore check:test_file rubocop-Ruby 2.5.3-Puppet ~> 6:
syntax lint metadata_lint check:symlinks check:git_ignore check:dot_underscore check:test_file rubocop-Ruby 2.5.7-Puppet ~> 6:
  stage: syntax
  image: ruby:2.5.3
  image: ruby:2.5.7
  script:
    - bundle exec rake syntax lint metadata_lint check:symlinks check:git_ignore check:dot_underscore check:test_file rubocop
  variables:
    PUPPET_GEM_VERSION: '~> 6'

parallel_spec-Ruby 2.5.3-Puppet ~> 6:
parallel_spec-Ruby 2.5.7-Puppet ~> 6:
  stage: unit
  image: ruby:2.5.3
  image: ruby:2.5.7
  script:
    - bundle exec rake parallel_spec
  variables:
+11 −0
Original line number Diff line number Diff line
@@ -27,6 +27,7 @@ GetText/DecorateString:
  Description: We don't want to decorate test output.
  Exclude:
  - spec/**/*
  Enabled: false
RSpec/BeforeAfterAll:
  Description: Beware of using after(:all) as it may cause state to leak between tests.
    A necessary evil in acceptance testing.
@@ -39,6 +40,10 @@ Style/BlockDelimiters:
  Description: Prefer braces for chaining. Mostly an aesthetical choice. Better to
    be consistent then.
  EnforcedStyle: braces_for_chaining
Style/BracesAroundHashParameters:
  Description: Braces are required by Ruby 2.7. Cop removed from RuboCop v0.80.0.
    See https://github.com/rubocop-hq/rubocop/pull/7643
  Enabled: true
Style/ClassAndModuleChildren:
  Description: Compact style reduces the required amount of indentation.
  EnforcedStyle: compact
@@ -88,6 +93,12 @@ Style/MethodCalledOnDoEndBlock:
  Enabled: true
Style/StringMethods:
  Enabled: true
GetText/DecorateFunctionMessage:
  Enabled: false
GetText/DecorateStringFormattingUsingInterpolation:
  Enabled: false
GetText/DecorateStringFormattingUsingPercent:
  Enabled: false
Layout/EndOfLine:
  Enabled: false
Layout/IndentHeredoc:

.sync.yml

0 → 100644
+3 −0
Original line number Diff line number Diff line
---
spec/spec_helper.rb:
  mock_with: ":rspec"
+8 −4
Original line number Diff line number Diff line
---
os: linux
dist: xenial
language: ruby
cache: bundler
before_install:
  - bundle -v
  - rm -f Gemfile.lock
  - gem update --system $RUBYGEMS_VERSION
  - "# Update system gems if requested. This is useful to temporarily workaround troubles in the test runner"
  - "# See https://github.com/puppetlabs/pdk-templates/commit/705154d5c437796b821691b707156e1b056d244f for an example of how this was used"
  - "# Ignore exit code of SIGPIPE'd yes to not fail with shell's pipefail set"
  - '[ -z "$RUBYGEMS_VERSION" ] || (yes || true) | gem update --system $RUBYGEMS_VERSION'
  - gem --version
  - bundle -v
script:
  - 'bundle exec rake $CHECK'
bundler_args: --without system_tests
rvm:
  - 2.5.3
  - 2.5.7
stages:
  - static
  - spec
@@ -20,7 +24,7 @@ stages:
  -
    if: tag =~ ^v\d
    name: deploy
matrix:
jobs:
  fast_finish: true
  include:
    -
@@ -32,7 +36,7 @@ matrix:
      stage: spec
    -
      env: PUPPET_GEM_VERSION="~> 6.0" CHECK=parallel_spec
      rvm: 2.5.3
      rvm: 2.5.7
      stage: spec
    -
      env: DEPLOY_TO_FORGE=yes
Loading