summaryrefslogtreecommitdiff
path: root/spec/bundler
diff options
context:
space:
mode:
authorDavid Rodríguez <deivid.rodriguez@riseup.net>2019-08-06 13:16:44 +0200
committerHiroshi SHIBATA <hsbt@ruby-lang.org>2019-08-17 17:08:49 +0900
commita2ca3a12ba35d8991099cb23be4bdeb15e5cd459 (patch)
treefa3d062bc888ec4e136363814f111b902b66a031 /spec/bundler
parent745b2861617c62413357e27de9ded8098fcc031d (diff)
[bundler/bundler] Remove unnecessary `let`
Use shared helper instead. https://github.com/bundler/bundler/commit/ef55470cc6
Diffstat (limited to 'spec/bundler')
-rw-r--r--spec/bundler/runtime/setup_spec.rb5
1 files changed, 2 insertions, 3 deletions
diff --git a/spec/bundler/runtime/setup_spec.rb b/spec/bundler/runtime/setup_spec.rb
index 748bbcbf23..abc8b454a5 100644
--- a/spec/bundler/runtime/setup_spec.rb
+++ b/spec/bundler/runtime/setup_spec.rb
@@ -804,7 +804,6 @@ end
context "with bundler is located in symlinked GEM_HOME" do
let(:gem_home) { Dir.mktmpdir }
let(:symlinked_gem_home) { Tempfile.new("gem_home").path }
- let(:bundler_dir) { ruby_core? ? File.expand_path("../../../..", __FILE__) : File.expand_path("../../..", __FILE__) }
let(:full_name) { "bundler-#{Bundler::VERSION}" }
before do
@@ -814,9 +813,9 @@ end
Dir.mkdir(gems_dir)
Dir.mkdir(specifications_dir)
- FileUtils.ln_s(bundler_dir, File.join(gems_dir, full_name))
+ FileUtils.ln_s(root, File.join(gems_dir, full_name))
- gemspec_file = ruby_core? ? "#{bundler_dir}/lib/bundler/bundler.gemspec" : "#{bundler_dir}/bundler.gemspec"
+ gemspec_file = ruby_core? ? "#{root}/lib/bundler/bundler.gemspec" : "#{root}/bundler.gemspec"
gemspec = File.binread(gemspec_file).
sub("Bundler::VERSION", %("#{Bundler::VERSION}"))
gemspec = gemspec.lines.reject {|line| line =~ %r{lib/bundler/version} }.join