diff options
author | Vít Ondruch <vondruch@redhat.com> | 2023-12-12 14:37:30 +0100 |
---|---|---|
committer | Hiroshi SHIBATA <hsbt@ruby-lang.org> | 2023-12-13 12:16:55 +0900 |
commit | 1fa5dd883e286a768a9dfa82ef3de562fcdabd01 (patch) | |
tree | 1fdd81f6deadd0b49ba6b8a8de71561acf2eb00a | |
parent | 402fd96ddc401cf35bced8d394c44df98d6fc466 (diff) |
[rubygems/rubygems] Test if the user dir is used for auto user installation
This is mainly to align this test case with the
`test_process_options_does_not_fallback_to_user_install_when_gem_home_
not_writable_and_no_user_install`, where the `install_dir` is checked
already.
https://github.com/rubygems/rubygems/commit/02b1884b61
-rw-r--r-- | test/rubygems/test_gem_installer.rb | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/test/rubygems/test_gem_installer.rb b/test/rubygems/test_gem_installer.rb index 3110ac63a6..edcc2216bd 100644 --- a/test/rubygems/test_gem_installer.rb +++ b/test/rubygems/test_gem_installer.rb @@ -1987,8 +1987,9 @@ end FileUtils.chmod 0o000, @gemhome - use_ui(@ui) { Gem::Installer.at @gem } + installer = use_ui(@ui) { Gem::Installer.at @gem } + assert_equal Gem.user_dir, installer.gem_home assert_equal "Defaulting to user installation because default installation directory (#{@gemhome}) is not writable.", @ui.output.strip ensure FileUtils.chmod 0o755, @gemhome |