Skip to content

Commit 8eaa209

Browse files
committed
Add rspec-github integration
This adds rspec-github as a dependency and at runtime it is optionally configured. The detection is the same as for Rubocop.
1 parent 920b340 commit 8eaa209

File tree

2 files changed

+5
-0
lines changed

2 files changed

+5
-0
lines changed

lib/puppetlabs_spec_helper/module_spec_helper.rb

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,10 @@ def verify_contents(subject, title, expected_lines)
6262
end
6363

6464
RSpec.configure do |c|
65+
if ENV['GITHUB_ACTIONS'] == 'true'
66+
c.formatter = 'RSpec::Github::Formatter'
67+
end
68+
6569
c.environmentpath = spec_path if Puppet.version.to_f >= 4.0
6670
c.module_path = module_path
6771
c.manifest_dir = File.join(fixture_path, 'manifests')

puppetlabs_spec_helper.gemspec

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,5 +32,6 @@ Gem::Specification.new do |spec|
3232
spec.add_runtime_dependency 'pathspec', '~> 1.0'
3333
spec.add_runtime_dependency 'puppet-lint', '~> 3.0'
3434
spec.add_runtime_dependency 'puppet-syntax', '~> 3.0'
35+
spec.add_runtime_dependency 'rspec-github', '~> 2.0'
3536
spec.add_runtime_dependency 'rspec-puppet', '~> 2.0'
3637
end

0 commit comments

Comments
 (0)