Skip to content

Commit

Permalink
update to PDK template 2.1.1 (#278)
Browse files Browse the repository at this point in the history
Signed-off-by: Michael Geiger <info@mgeiger.de>
  • Loading branch information
mcgege committed Jul 9, 2021
1 parent cfe2d99 commit ba7e3d8
Show file tree
Hide file tree
Showing 5 changed files with 19 additions and 13 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@
.project
.envrc
/inventory.yaml
/spec/fixtures/litmus_inventory.yaml
/.kitchen/
/test/fixtures/.librarian/
/test/fixtures/.tmp/
Expand Down
3 changes: 3 additions & 0 deletions .pdkignore
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,9 @@
.project
.envrc
/inventory.yaml
/spec/fixtures/litmus_inventory.yaml
/appveyor.yml
/.editorconfig
/.fixtures.yml
/Gemfile
/.gitattributes
Expand All @@ -42,6 +44,7 @@
/spec/
/.vscode/
/.sync.yml
/.devcontainer/
/.kitchen/
/test/fixtures/.librarian/
/test/fixtures/.tmp/
Expand Down
10 changes: 0 additions & 10 deletions Gemfile
Original file line number Diff line number Diff line change
Expand Up @@ -60,16 +60,6 @@ gems['puppet'] = location_for(puppet_version)
gems['facter'] = location_for(facter_version) if facter_version
gems['hiera'] = location_for(hiera_version) if hiera_version

if Gem.win_platform? && puppet_version =~ %r{^(file:///|git://)}
# If we're using a Puppet gem on Windows which handles its own win32-xxx gem
# dependencies (>= 3.5.0), set the maximum versions (see PUP-6445).
gems['win32-dir'] = ['<= 0.4.9', require: false]
gems['win32-eventlog'] = ['<= 0.6.5', require: false]
gems['win32-process'] = ['<= 0.7.5', require: false]
gems['win32-security'] = ['<= 0.2.5', require: false]
gems['win32-service'] = ['0.8.8', require: false]
end

gems.each do |gem_name, gem_params|
gem gem_name, *gem_params
end
Expand Down
6 changes: 3 additions & 3 deletions metadata.json
Original file line number Diff line number Diff line change
Expand Up @@ -82,7 +82,7 @@
"version_requirement": ">= 5.0.0 < 7.0.0"
}
],
"template-url": "https://github.com/dev-sec/puppet-pdk-template#2.0.0",
"pdk-version": "2.0.0",
"template-ref": "tags/2.0.0-0-ge838f1d"
"template-url": "https://github.com/dev-sec/puppet-pdk-template#2.1.1",
"pdk-version": "2.1.1",
"template-ref": "tags/2.1.1-0-g03daa92"
}
12 changes: 12 additions & 0 deletions spec/spec_helper.rb
Original file line number Diff line number Diff line change
Expand Up @@ -47,6 +47,18 @@
c.filter_run_excluding(bolt: true) unless ENV['GEM_BOLT']
c.after(:suite) do
end

# Filter backtrace noise
backtrace_exclusion_patterns = [
%r{spec_helper},
%r{gems},
]

if c.respond_to?(:backtrace_exclusion_patterns)
c.backtrace_exclusion_patterns = backtrace_exclusion_patterns
elsif c.respond_to?(:backtrace_clean_patterns)
c.backtrace_clean_patterns = backtrace_exclusion_patterns
end
end

# Ensures that a module is defined
Expand Down

0 comments on commit ba7e3d8

Please sign in to comment.