summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorTim Moore <tmoore@incrementalism.net>2014-07-17 14:34:03 +1000
committerTim Moore <tmoore@incrementalism.net>2014-07-30 14:16:37 +1000
commit65a647df088f2b59994eeabafbaf7ac425f82ea5 (patch)
tree8757fca5dfb5225ff50d002ece0980d309ab9ff3
parente5bdbddb618394b4ae2b1b47ec6437ccd9aba264 (diff)
downloadbundler-65a647df088f2b59994eeabafbaf7ac425f82ea5.tar.gz
Add a spec for gems not in the pinned source.
-rw-r--r--spec/install/gems/sources_spec.rb18
1 files changed, 18 insertions, 0 deletions
diff --git a/spec/install/gems/sources_spec.rb b/spec/install/gems/sources_spec.rb
index cd4bcf1992..d45e25c754 100644
--- a/spec/install/gems/sources_spec.rb
+++ b/spec/install/gems/sources_spec.rb
@@ -208,6 +208,24 @@ describe "bundle install with gems on multiple sources" do
end
end
end
+
+ context "with a gem that is only found in the wrong source" do
+ before do
+ build_repo gem_repo3 do
+ build_gem "not_in_repo1", "1.0.0"
+ end
+
+ gemfile <<-G
+ source "file://#{gem_repo3}"
+ gem "not_in_repo1", :source => "file://#{gem_repo1}"
+ G
+ end
+
+ it "does not install the gem" do
+ bundle :install
+ expect(out).to include("Could not find gem 'not_in_repo1 (>= 0) ruby'")
+ end
+ end
end
context "when an older version of the same gem also ships with Ruby" do