Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 11 additions & 0 deletions .github/workflows/ruby.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,24 @@ jobs:
- '3.4'
- jruby
- truffleruby
include:
- ruby: '3.0'
rubygems_version: '3.5.23'
- ruby: '3.1'
rubygems_version: '3.6.9'
name: Ruby ${{ matrix.ruby }}
steps:
- uses: actions/checkout@v2
- name: Set up Ruby
uses: ruby/setup-ruby@v1
with:
ruby-version: ${{ matrix.ruby }}
- name: Update RubyGems
env:
RUBYGEMS_VERSION: ${{ matrix.rubygems_version }}
run: |
gem update --system ${RUBYGEMS_VERSION:-}
gem -v
- name: Install dependencies
run: bundle install --jobs 4 --retry 3
- name: Run tests
Expand Down
18 changes: 16 additions & 2 deletions spec/integration_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,14 @@
subject { sh(command) }

it "must invoke the CLI class" do
expect(subject).to eq("bundler-audit #{Bundler::Audit::VERSION}#{$/}")
expected = "bundler-audit #{Bundler::Audit::VERSION}#{$/}"

if RUBY_VERSION.start_with?("3.0") || RUBY_ENGINE == "truffleruby"
# Allow `WARN: Unresolved or ambiguous specs during Gem::Specification.reset:` for Ruby 3.0.x and TruffleRuby
expect(subject).to include(expected)
else
expect(subject).to eq(expected)
end
end
end

Expand All @@ -26,6 +33,13 @@
subject { sh(command) }

it "must invoke the CLI class" do
expect(subject).to eq("bundler-audit #{Bundler::Audit::VERSION}#{$/}")
expected = "bundler-audit #{Bundler::Audit::VERSION}#{$/}"

if RUBY_VERSION.start_with?("3.0") || RUBY_ENGINE == "truffleruby"
# Allow `WARN: Unresolved or ambiguous specs during Gem::Specification.reset:` for Ruby 3.0.x and TruffleRuby
expect(subject).to include(expected)
else
expect(subject).to eq(expected)
end
end
end