[rubygems/rubygems] Prefer the standard separator on Windows

It seems like the most common case since it requires no tricks on our
CI environment.

Co-authored-by: MSP-Greg <MSP-Greg@users.noreply.github.com>

https://github.com/rubygems/rubygems/commit/751c475574
This commit is contained in:
David Rodríguez 2020-07-14 13:16:09 +02:00 committed by Hiroshi SHIBATA
parent 65a4b03781
commit c090c64b4f
Notes: git 2020-07-31 21:08:22 +09:00
2 changed files with 3 additions and 3 deletions

View File

@ -704,7 +704,7 @@ class Gem::Installer
return if self.class.path_warning
user_bin_dir = @bin_dir || Gem.bindir(gem_home)
user_bin_dir = user_bin_dir.tr(File::SEPARATOR, File::ALT_SEPARATOR) if
user_bin_dir = user_bin_dir.tr(File::ALT_SEPARATOR, File::SEPARATOR) if
File::ALT_SEPARATOR
path = ENV['PATH']

View File

@ -196,7 +196,7 @@ gem 'other', version
bin_dir = installer.bin_dir
if Gem.win_platform?
bin_dir = bin_dir.downcase.gsub(File::SEPARATOR, File::ALT_SEPARATOR)
bin_dir = bin_dir.downcase
end
orig_PATH, ENV['PATH'] =
@ -239,7 +239,7 @@ gem 'other', version
expected = installer.bin_dir
if Gem.win_platform?
expected = expected.downcase.gsub(File::SEPARATOR, File::ALT_SEPARATOR)
expected = expected.downcase
end
assert_match expected, @ui.error