summaryrefslogtreecommitdiff
path: root/test/rubygems/test_gem_commands_setup_command.rb
diff options
context:
space:
mode:
authorDavid Rodríguez <deivid.rodriguez@riseup.net>2019-04-26 13:26:21 +0200
committerHiroshi SHIBATA <hsbt@ruby-lang.org>2019-04-28 11:07:45 +0900
commitd0a54673202458455244f79ed212a97727f0c7c7 (patch)
tree4d984b9e2675d906b3e336c7f951f03b11316546 /test/rubygems/test_gem_commands_setup_command.rb
parenta15f7dd1fb1148c3d586238ee6907875f2e40379 (diff)
Update rubygems with latest upstream changes
Closes: https://github.com/ruby/ruby/pull/2154
Diffstat (limited to 'test/rubygems/test_gem_commands_setup_command.rb')
-rw-r--r--test/rubygems/test_gem_commands_setup_command.rb25
1 files changed, 8 insertions, 17 deletions
diff --git a/test/rubygems/test_gem_commands_setup_command.rb b/test/rubygems/test_gem_commands_setup_command.rb
index 87ec5c204c..3f9887eedf 100644
--- a/test/rubygems/test_gem_commands_setup_command.rb
+++ b/test/rubygems/test_gem_commands_setup_command.rb
@@ -135,24 +135,17 @@ class TestGemCommandsSetupCommand < Gem::TestCase
gem_exec = sprintf Gem.default_exec_format, 'gem'
default_gem_bin_path = File.join @install_dir, 'bin', gem_exec
- if Gem::USE_BUNDLER_FOR_GEMDEPS
- bundle_exec = sprintf Gem.default_exec_format, 'bundle'
- default_bundle_bin_path = File.join @install_dir, 'bin', bundle_exec
- end
-
+ bundle_exec = sprintf Gem.default_exec_format, 'bundle'
+ default_bundle_bin_path = File.join @install_dir, 'bin', bundle_exec
ruby_exec = sprintf Gem.default_exec_format, 'ruby'
if Gem.win_platform?
assert_match %r%\A#!\s*#{ruby_exec}%, File.read(default_gem_bin_path)
- if Gem::USE_BUNDLER_FOR_GEMDEPS
- assert_match %r%\A#!\s*#{ruby_exec}%, File.read(default_bundle_bin_path)
- end
+ assert_match %r%\A#!\s*#{ruby_exec}%, File.read(default_bundle_bin_path)
assert_match %r%\A#!\s*#{ruby_exec}%, File.read(gem_bin_path)
else
assert_match %r%\A#!/usr/bin/env #{ruby_exec}%, File.read(default_gem_bin_path)
- if Gem::USE_BUNDLER_FOR_GEMDEPS
- assert_match %r%\A#!/usr/bin/env #{ruby_exec}%, File.read(default_bundle_bin_path)
- end
+ assert_match %r%\A#!/usr/bin/env #{ruby_exec}%, File.read(default_bundle_bin_path)
assert_match %r%\A#!/usr/bin/env #{ruby_exec}%, File.read(gem_bin_path)
end
end
@@ -176,10 +169,8 @@ class TestGemCommandsSetupCommand < Gem::TestCase
assert_path_exists File.join(dir, 'rubygems.rb')
assert_path_exists File.join(dir, 'rubygems/ssl_certs/rubygems.org/foo.pem')
- if Gem::USE_BUNDLER_FOR_GEMDEPS
- assert_path_exists File.join(dir, 'bundler.rb')
- assert_path_exists File.join(dir, 'bundler/b.rb')
- end
+ assert_path_exists File.join(dir, 'bundler.rb')
+ assert_path_exists File.join(dir, 'bundler/b.rb')
end
end
@@ -223,7 +214,7 @@ class TestGemCommandsSetupCommand < Gem::TestCase
# expect to not remove bundler-* direcotyr.
assert_path_exists 'default/gems/bundler-audit-1.0.0'
- end if Gem::USE_BUNDLER_FOR_GEMDEPS
+ end
def test_remove_old_lib_files
lib = File.join @install_dir, 'lib'
@@ -271,7 +262,7 @@ class TestGemCommandsSetupCommand < Gem::TestCase
refute_path_exists old_builder_rb
refute_path_exists old_format_rb
- refute_path_exists old_bundler_c_rb if Gem::USE_BUNDLER_FOR_GEMDEPS
+ refute_path_exists old_bundler_c_rb
assert_path_exists securerandom_rb
assert_path_exists engine_defaults_rb