aboutsummaryrefslogtreecommitdiffstats
path: root/lib/rubygems/test_case.rb
diff options
context:
space:
mode:
Diffstat (limited to 'lib/rubygems/test_case.rb')
-rw-r--r--lib/rubygems/test_case.rb19
1 files changed, 15 insertions, 4 deletions
diff --git a/lib/rubygems/test_case.rb b/lib/rubygems/test_case.rb
index 691985dcd2..ebfe979a1b 100644
--- a/lib/rubygems/test_case.rb
+++ b/lib/rubygems/test_case.rb
@@ -78,6 +78,20 @@ module Gem
end
end
+require "rubygems/command"
+
+class Gem::Command
+
+ ##
+ # Allows resetting the hash of specific args per command. This method is
+ # available when requiring 'rubygems/test_case'
+
+ def self.specific_extra_args_hash=(value)
+ @specific_extra_args_hash = value
+ end
+
+end
+
##
# RubyGemTestCase provides a variety of methods for testing rubygems and
# gem-related behavior in a sandbox. Through RubyGemTestCase you can install
@@ -1246,10 +1260,7 @@ Also, a list:
end
begin
- require "rbconfig"
- File.join(RbConfig::CONFIG["bindir"],
- RbConfig::CONFIG["ruby_install_name"] +
- RbConfig::CONFIG["EXEEXT"])
+ Gem.ruby
rescue LoadError
"ruby"
end