summaryrefslogtreecommitdiff
path: root/spec/install/gems/resolving_spec.rb
diff options
context:
space:
mode:
authorSamuel Giddins <segiddins@segiddins.me>2016-08-09 13:01:00 -0500
committerSamuel Giddins <segiddins@segiddins.me>2016-08-23 11:50:35 -0500
commit8de41cb9b045c1897138ba5e2e1ae9ae5cdb3369 (patch)
treef44afcc1708b5399b877a466ca91c726c55a0338 /spec/install/gems/resolving_spec.rb
parentb5c038822229813f01f685afc2e51e7c9ad643be (diff)
downloadbundler-8de41cb9b045c1897138ba5e2e1ae9ae5cdb3369.tar.gz
Use the resolver to resolve for ruby / rubygems versions
Diffstat (limited to 'spec/install/gems/resolving_spec.rb')
-rw-r--r--spec/install/gems/resolving_spec.rb17
1 files changed, 10 insertions, 7 deletions
diff --git a/spec/install/gems/resolving_spec.rb b/spec/install/gems/resolving_spec.rb
index 90c07adf10..5939a2f875 100644
--- a/spec/install/gems/resolving_spec.rb
+++ b/spec/install/gems/resolving_spec.rb
@@ -126,23 +126,26 @@ describe "bundle install with install-time dependencies" do
end
end
- install_gemfile <<-G
- source "file://#{gem_repo2}"
+ install_gemfile <<-G, :artifice => "compact_index", :env => { "BUNDLER_SPEC_GEM_REPO" => gem_repo2 }
+ source "http://localgemserver.test/"
ruby "#{RUBY_VERSION}"
gem 'require_ruby'
G
expect(out).to_not include("Gem::InstallError: require_ruby requires Ruby version > 9000")
- nice_error = <<-E.strip.gsub(/^ {8}/, "")
- Fetching source index from file:#{gem_repo1}/
+ nice_error = strip_whitespace(<<-E).strip
+ Fetching gem metadata from http://localgemserver.test/.
+ Fetching version metadata from http://localgemserver.test/
Resolving dependencies...
- Bundler could not find compatible versions for gem "require_ruby":
+ Bundler could not find compatible versions for gem "ruby\0":
In Gemfile:
- ruby (= #{RUBY_VERSION})
+ ruby\0 (= 2.3.1)
require_ruby was resolved to 1.0, which depends on
- ruby (> 9000)
+ ruby\0 (> 9000)
+
+ Could not find gem 'ruby\0 (> 9000)', which is required by gem 'require_ruby', in any of the sources.
E
expect(out).to eq(nice_error)
end