diff options
author | The Bundler Bot <bot@bundler.io> | 2017-11-30 15:19:20 +0000 |
---|---|---|
committer | SHIBATA Hiroshi <hsbt@ruby-lang.org> | 2017-12-11 20:42:18 +0900 |
commit | 2875b6e0c28ed3e9c1f4986c1f6d70a409c1d31e (patch) | |
tree | 4f9fd83994ca63120edd03d0fdab8563e97a6487 /spec/realworld | |
parent | 3a0c85f4d38bea24e9393a98dc951d081361d586 (diff) | |
download | bundler-2875b6e0c28ed3e9c1f4986c1f6d70a409c1d31e.tar.gz |
Auto merge of #6188 - bundler:indirect/fix-6072, r=indirect
Stop overriding specs during double-checks
This fixes my test-case reproduction of #6072. I’m pretty sure it’s because
the double-check was overriding the locally installed index specs with
specs fetched from the RubyGems API, causing Bundler to conclude that the
gems aren’t installed, even though they are.
@deivid-rodriguez @y-yagi can you verify that this patch fixes the issues with `inline` that you were seeing?
Diffstat (limited to 'spec/realworld')
-rw-r--r-- | spec/realworld/double_check_spec.rb | 40 |
1 files changed, 40 insertions, 0 deletions
diff --git a/spec/realworld/double_check_spec.rb b/spec/realworld/double_check_spec.rb new file mode 100644 index 0000000000..6fee578a71 --- /dev/null +++ b/spec/realworld/double_check_spec.rb @@ -0,0 +1,40 @@ +# frozen_string_literal: true + +RSpec.describe "double checking sources", :realworld => true do + it "finds already-installed gems" do + create_file("rails.gemspec", <<-RUBY) + Gem::Specification.new do |s| + s.name = "rails" + s.version = "5.1.4" + s.summary = "" + s.description = "" + s.author = "" + s.add_dependency "actionpack", "5.1.4" + end + RUBY + + create_file("actionpack.gemspec", <<-RUBY) + Gem::Specification.new do |s| + s.name = "actionpack" + s.version = "5.1.4" + s.summary = "" + s.description = "" + s.author = "" + s.add_dependency "rack", "~> 2.0.0" + end + RUBY + + cmd = <<-RUBY + require "bundler" + require #{File.expand_path("../../support/artifice/vcr.rb", __FILE__).dump} + require "bundler/inline" + gemfile(true) do + source "https://rubygems.org" + gem "rails", path: "." + end + RUBY + + ruby! cmd + ruby! cmd + end +end |