Skip to content

Commit

Permalink
Test bundler version greater than behavior
Browse files Browse the repository at this point in the history
Add test to assert versions greater than 2.6 will receive 2.6
  • Loading branch information
schneems committed Jan 6, 2025
1 parent 64fb859 commit 4e6b882
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions spec/helpers/bundler_wrapper_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,10 @@
expect(wrapper_klass::BLESSED_BUNDLER_VERSIONS.key?("2.6")).to be_truthy
expect(version).to eq(wrapper_klass::BLESSED_BUNDLER_VERSIONS["2.6"])

version = wrapper_klass.detect_bundler_version(contents: "BUNDLED WITH\n 2.999.7")
expect(wrapper_klass::BLESSED_BUNDLER_VERSIONS.key?("2.6")).to be_truthy
expect(version).to eq(wrapper_klass::BLESSED_BUNDLER_VERSIONS["2.6"])

expect {
wrapper_klass.detect_bundler_version(contents: "BUNDLED WITH\n 3.6.7")
}.to raise_error(wrapper_klass::UnsupportedBundlerVersion)
Expand Down

0 comments on commit 4e6b882

Please sign in to comment.