diff options
author | David RodrÃguez <[email protected]> | 2025-05-30 12:07:59 +0200 |
---|---|---|
committer | Hiroshi SHIBATA <[email protected]> | 2025-06-03 08:12:09 +0900 |
commit | 6f4eaa100f3b1afd0edf99a7f7fa09a17732ff54 (patch) | |
tree | 19fd39b21226587163fd64b9486beacedcaae3f5 | |
parent | 710f5b771155dcb4786014c8fd7b767a08f4d6f6 (diff) |
Remove hardcoded version of rake from Bundler tests
Let them run against the version resolved by the `test_gems.rb` gemfile.
This should fix ruby-core CI job that was broken by the release of rake
13.3.0.
-rw-r--r-- | spec/bundler/commands/check_spec.rb | 4 | ||||
-rw-r--r-- | spec/bundler/support/builders.rb | 4 | ||||
-rw-r--r-- | spec/bundler/support/path.rb | 4 |
3 files changed, 6 insertions, 6 deletions
diff --git a/spec/bundler/commands/check_spec.rb b/spec/bundler/commands/check_spec.rb index fe47d54cb6..150ee62878 100644 --- a/spec/bundler/commands/check_spec.rb +++ b/spec/bundler/commands/check_spec.rb @@ -57,7 +57,7 @@ RSpec.describe "bundle check" do bundle :check, raise_on_error: false expect(err).to include("The following gems are missing") - expect(err).to include(" * rake (13.3.0)") + expect(err).to include(" * rake (#{rake_version})") expect(err).to include(" * actionpack (2.3.2)") expect(err).to include(" * activerecord (2.3.2)") expect(err).to include(" * actionmailer (2.3.2)") @@ -76,7 +76,7 @@ RSpec.describe "bundle check" do expect(exitstatus).to be > 0 expect(err).to include("The following gems are missing") expect(err).to include(" * rails (2.3.2)") - expect(err).to include(" * rake (13.3.0)") + expect(err).to include(" * rake (#{rake_version})") expect(err).to include(" * actionpack (2.3.2)") expect(err).to include(" * activerecord (2.3.2)") expect(err).to include(" * actionmailer (2.3.2)") diff --git a/spec/bundler/support/builders.rb b/spec/bundler/support/builders.rb index a4f2ecbdf1..e94ca5bfc5 100644 --- a/spec/bundler/support/builders.rb +++ b/spec/bundler/support/builders.rb @@ -24,10 +24,6 @@ module Spec Gem::Platform.new(platform) end - def rake_version - "13.3.0" - end - def build_repo1 build_repo gem_repo1 do FileUtils.cp rake_path, "#{gem_repo1}/gems/" diff --git a/spec/bundler/support/path.rb b/spec/bundler/support/path.rb index 6f7ee589c2..b08a68f111 100644 --- a/spec/bundler/support/path.rb +++ b/spec/bundler/support/path.rb @@ -284,6 +284,10 @@ module Spec Dir["#{base_system_gems}/*/*/**/rake*.gem"].first end + def rake_version + File.basename(rake_path).delete_prefix("rake-").delete_suffix(".gem") + end + def sinatra_dependency_paths deps = %w[ mustermann |