зеркало из https://github.com/github/ruby.git
[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:
Родитель
65a4b03781
Коммит
c090c64b4f
|
@ -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']
|
||||
|
|
|
@ -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
|
||||
|
|
Загрузка…
Ссылка в новой задаче