Fix a few warnings while running specs #2115

Merged
merged 1 commit into from Oct 2, 2012
@@ -235,7 +235,7 @@ def lock(file)
end
File.open(file, 'wb'){|f| f.puts(contents) }
- rescue Errno::EACCES => e
+ rescue Errno::EACCES
raise Bundler::InstallError,
"There was an error while trying to write to Gemfile.lock. It is likely that \n" \
"you need to allow write permissions for the file at path: \n" \
View
@@ -142,8 +142,7 @@
end
it "displays warning message when detecting git repo in Gemfile" do
- git = build_git "foo"
- ref = git.ref_for("master", 11)
+ build_git "foo"
install_gemfile <<-G
gem "foo", :git => '#{lib_path("foo-1.0")}'
@@ -155,8 +154,7 @@
end
it "does not display warning message if cache_all is set in bundle config" do
- git = build_git "foo"
- ref = git.ref_for("master", 11)
+ build_git "foo"
install_gemfile <<-G
gem "foo", :git => '#{lib_path("foo-1.0")}'
@@ -168,4 +166,4 @@
out.should_not include("Your Gemfile contains path and git dependencies.")
end
end
-end
+end
@@ -29,8 +29,6 @@
gemfile ""
bundle "install --path vendor/bundle"
- gem_path = ENV['GEM_PATH']
-
code = "Bundler.with_clean_env do;" +
" print ENV['GEM_PATH'] != '';" +
"end"