summaryrefslogtreecommitdiff
path: root/test/rubygems/test_gem_commands_environment_command.rb
diff options
context:
space:
mode:
Diffstat (limited to 'test/rubygems/test_gem_commands_environment_command.rb')
-rw-r--r--test/rubygems/test_gem_commands_environment_command.rb15
1 files changed, 15 insertions, 0 deletions
diff --git a/test/rubygems/test_gem_commands_environment_command.rb b/test/rubygems/test_gem_commands_environment_command.rb
index 0913888a6d..5568478652 100644
--- a/test/rubygems/test_gem_commands_environment_command.rb
+++ b/test/rubygems/test_gem_commands_environment_command.rb
@@ -62,6 +62,21 @@ class TestGemCommandsEnvironmentCommand < RubyGemTestCase
assert_equal '', @ui.error
end
+ def test_execute_gempath_multiple
+ Gem.clear_paths
+ path = [@gemhome, "#{@gemhome}2"].join File::PATH_SEPARATOR
+ ENV['GEM_PATH'] = path
+
+ @cmd.send :handle_options, %w[gempath]
+
+ use_ui @ui do
+ @cmd.execute
+ end
+
+ assert_equal "#{Gem.path.join File::PATH_SEPARATOR}\n", @ui.output
+ assert_equal '', @ui.error
+ end
+
def test_execute_packageversion
@cmd.send :handle_options, %w[packageversion]