Exit with non-zero status on disabled gem system update.
This commit is contained in:
parent
3ab1cfc325
commit
7a571103f2
Notes:
git
2020-06-15 21:21:01 +09:00
@ -264,7 +264,7 @@ command to remove old versions.
|
||||
def update_rubygems
|
||||
if Gem.disable_system_update_message
|
||||
alert_error Gem.disable_system_update_message
|
||||
return
|
||||
terminate_interaction 1
|
||||
end
|
||||
|
||||
check_update_arguments
|
||||
|
@ -245,8 +245,10 @@ class TestGemCommandsUpdateCommand < Gem::TestCase
|
||||
@cmd.options[:args] = []
|
||||
@cmd.options[:system] = true
|
||||
|
||||
use_ui @ui do
|
||||
@cmd.execute
|
||||
assert_raises Gem::MockGemUi::TermError do
|
||||
use_ui @ui do
|
||||
@cmd.execute
|
||||
end
|
||||
end
|
||||
|
||||
assert_empty @ui.output
|
||||
|
Loading…
x
Reference in New Issue
Block a user