diff options
author | The Bundler Bot <bot@bundler.io> | 2018-03-01 08:28:27 +0000 |
---|---|---|
committer | Colby Swandale <me@colby.fyi> | 2018-04-20 10:27:32 +1000 |
commit | c0dc6a5df196096657782c1d4216a2a3dcb1545e (patch) | |
tree | 37fd432764087df1ce20a730dabebac9f186115c /spec | |
parent | 5edf035cbcf55d43393b70408db706f0da5446cd (diff) | |
download | bundler-c0dc6a5df196096657782c1d4216a2a3dcb1545e.tar.gz |
Auto merge of #6314 - bundler:update-deprecated-methods, r=hsbt
Use Gem::Util.inflate instead of Gem.inflate
### What was the end-user problem that led to this PR?
When I released RubyGems 3.0, users can not use bundler with it.
### What was your diagnosis of the problem?
bundler still uses deprecated methods with https://github.com/rubygems/rubygems/pull/2214
### What is your fix for the problem, implemented in this PR?
Replace `Gem.inflate` to `Gem::Util.inflate`
(cherry picked from commit ba63d2eab7d321091cbe3482521c8da021e10c70)
Diffstat (limited to 'spec')
-rw-r--r-- | spec/install/gems/resolving_spec.rb | 2 | ||||
-rw-r--r-- | spec/support/artifice/compact_index.rb | 2 | ||||
-rw-r--r-- | spec/support/artifice/endpoint.rb | 2 |
3 files changed, 3 insertions, 3 deletions
diff --git a/spec/install/gems/resolving_spec.rb b/spec/install/gems/resolving_spec.rb index d3df4c4bea..cf9f19980a 100644 --- a/spec/install/gems/resolving_spec.rb +++ b/spec/install/gems/resolving_spec.rb @@ -22,7 +22,7 @@ RSpec.describe "bundle install with install-time dependencies" do build_repo2 path = "#{gem_repo2}/#{Gem::MARSHAL_SPEC_DIR}/actionpack-2.3.2.gemspec.rz" - spec = Marshal.load(Gem.inflate(File.read(path))) + spec = Marshal.load(Gem::Util.inflate(File.read(path))) spec.dependencies.each do |d| d.instance_variable_set(:@type, :fail) end diff --git a/spec/support/artifice/compact_index.rb b/spec/support/artifice/compact_index.rb index 123efe3c58..2db2cd2c27 100644 --- a/spec/support/artifice/compact_index.rb +++ b/spec/support/artifice/compact_index.rb @@ -10,7 +10,7 @@ class CompactIndexAPI < Endpoint def load_spec(name, version, platform, gem_repo) full_name = "#{name}-#{version}" full_name += "-#{platform}" if platform != "ruby" - Marshal.load(Gem.inflate(File.open(gem_repo.join("quick/Marshal.4.8/#{full_name}.gemspec.rz")).read)) + Marshal.load(Gem::Util.inflate(File.open(gem_repo.join("quick/Marshal.4.8/#{full_name}.gemspec.rz")).read)) end def etag_response diff --git a/spec/support/artifice/endpoint.rb b/spec/support/artifice/endpoint.rb index 9afecff8e6..84dbcfd345 100644 --- a/spec/support/artifice/endpoint.rb +++ b/spec/support/artifice/endpoint.rb @@ -68,7 +68,7 @@ class Endpoint < Sinatra::Base def load_spec(name, version, platform, gem_repo) full_name = "#{name}-#{version}" full_name += "-#{platform}" if platform != "ruby" - Marshal.load(Gem.inflate(File.open(gem_repo.join("quick/Marshal.4.8/#{full_name}.gemspec.rz")).read)) + Marshal.load(Gem::Util.inflate(File.open(gem_repo.join("quick/Marshal.4.8/#{full_name}.gemspec.rz")).read)) end end |