summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authornagachika <nagachika@ruby-lang.org>2022-02-12 16:55:40 +0900
committernagachika <nagachika@ruby-lang.org>2022-02-12 17:12:32 +0900
commitea04e3fff7401cbf0a45f39351c7eb9c9dd6030e (patch)
treef7cf96dfd8fda663fd2bcc8068b38ac0c313b610
parent034872d6a66916fb2859f41d380ce503c84a65e8 (diff)
Fix bundler test failures.
These failures are caused by the incompatibility in keyword argument treatment in rspec-mocks. I fix the expectations in the bundler/rubygems_integration_spec.rb. These tests are not touched in the master branch. It seems that the following patch also fix the failures. But I believe the expectations in these tests are wrong. We should pass a Hash literal explicitly. --- a/common.mk +++ b/common.mk @@ -1365,7 +1365,7 @@ yes-test-bundler-precheck: main no-test-bundler-prepare: no-test-bundler-precheck yes-test-bundler-prepare: yes-test-bundler-precheck $(XRUBY) -C "$(srcdir)" bin/gem install --no-document \ - --install-dir .bundle --conservative "rspec:~> 3.8" "rake:~> 13.0" "parallel_tests:~> 2.29" + --install-dir .bundle --conservative "rspec-core:= 3.10.1" "rspec-expectations:= 3.10.1" "rspec-mocks:= 3.10.2" "rake:~> 13.0" "parallel_tests:~> 2.29" RSPECOPTS = BUNDLER_SPECS =
-rw-r--r--spec/bundler/bundler/rubygems_integration_spec.rb4
-rw-r--r--version.h2
2 files changed, 3 insertions, 3 deletions
diff --git a/spec/bundler/bundler/rubygems_integration_spec.rb b/spec/bundler/bundler/rubygems_integration_spec.rb
index 94abf70ddd..7557c806fe 100644
--- a/spec/bundler/bundler/rubygems_integration_spec.rb
+++ b/spec/bundler/bundler/rubygems_integration_spec.rb
@@ -54,7 +54,7 @@ RSpec.describe Bundler::RubygemsIntegration do
it "successfully downloads gem with retries" do
expect(Bundler.rubygems).to receive(:gem_remote_fetcher).and_return(fetcher)
- expect(fetcher).to receive(:headers=).with("X-Gemfile-Source" => "https://foo.bar")
+ expect(fetcher).to receive(:headers=).with({ "X-Gemfile-Source" => "https://foo.bar" })
expect(Bundler::Retry).to receive(:new).with("download gem from #{uri}/").
and_return(bundler_retry)
expect(bundler_retry).to receive(:attempts).and_yield
@@ -76,7 +76,7 @@ RSpec.describe Bundler::RubygemsIntegration do
it "sets the 'X-Gemfile-Source' header containing the original source" do
expect(Bundler.rubygems).to receive(:gem_remote_fetcher).twice.and_return(fetcher)
- expect(fetcher).to receive(:headers=).with("X-Gemfile-Source" => "http://zombo.com").twice
+ expect(fetcher).to receive(:headers=).with({ "X-Gemfile-Source" => "http://zombo.com" }).twice
expect(fetcher).to receive(:fetch_path).with(uri + "specs.4.8.gz").and_return(specs_response)
expect(fetcher).to receive(:fetch_path).with(uri + "prerelease_specs.4.8.gz").and_return(prerelease_specs_response)
result = Bundler.rubygems.fetch_all_remote_specs(remote_with_mirror)
diff --git a/version.h b/version.h
index f74699f971..0a27f7df31 100644
--- a/version.h
+++ b/version.h
@@ -12,7 +12,7 @@
# define RUBY_VERSION_MINOR RUBY_API_VERSION_MINOR
#define RUBY_VERSION_TEENY 4
#define RUBY_RELEASE_DATE RUBY_RELEASE_YEAR_STR"-"RUBY_RELEASE_MONTH_STR"-"RUBY_RELEASE_DAY_STR
-#define RUBY_PATCHLEVEL 165
+#define RUBY_PATCHLEVEL 166
#define RUBY_RELEASE_YEAR 2022
#define RUBY_RELEASE_MONTH 2