summaryrefslogtreecommitdiff
path: root/spec/cache
diff options
context:
space:
mode:
authorSmit Shah <who828@gmail.com>2014-04-26 12:54:49 +0530
committerAndre Arko <andre@arko.net>2014-05-11 09:55:24 +0100
commitcc2474d02d596368739138b0a2ec4f052f925159 (patch)
treeca2bcf66ddae9b1af355cda957816b1d538114de /spec/cache
parent6a5ac82ee1853c563358bdfb188dc0fa4bc41de6 (diff)
downloadbundler-cc2474d02d596368739138b0a2ec4f052f925159.tar.gz
Added the test to check if install --local doesn't fetch specs remotely
Diffstat (limited to 'spec/cache')
-rw-r--r--spec/cache/gems_spec.rb14
1 files changed, 14 insertions, 0 deletions
diff --git a/spec/cache/gems_spec.rb b/spec/cache/gems_spec.rb
index 75158c451b..9386164c6f 100644
--- a/spec/cache/gems_spec.rb
+++ b/spec/cache/gems_spec.rb
@@ -103,6 +103,20 @@ describe "bundle cache" do
expect(bundled_app("vendor/cache/rack-1.0.0.gem")).to exist
expect(bundled_app("vendor/cache/builtin_gem-1.0.2.gem")).to exist
end
+
+ it "doesn't make remote request after caching the gem" do
+ build_gem "builtin_gem_2", "1.0.2", :path => bundled_app('vendor/cache') do |s|
+ s.summary = "This builtin_gem is bundled with Ruby"
+ end
+
+ install_gemfile <<-G
+ source "file://#{gem_repo2}"
+ gem 'builtin_gem_2', '1.0.2'
+ G
+
+ bundle "install --local"
+ should_be_installed("builtin_gem_2 1.0.2")
+ end
end
describe "when there are also git sources" do