summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authornobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2014-01-08 08:13:56 +0000
committernobu <nobu@b2dd03c8-39d4-4d8f-98ff-823fe69b080e>2014-01-08 08:13:56 +0000
commitfe46b2d5f05057dd2d238d71fc2276406d259cef (patch)
tree019255387055d42d2d3f141730f173baa8a476d8
parentab6efa5be2f5a2fb1b5a05a90f398b27ea52617a (diff)
rubygems/test_case.rb: fix errors in mkmf tests
* lib/rubygems/test_case.rb (Gem#teardown): BASERUBY is not set usually. fix errors in mkmf tests. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@44526 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
-rw-r--r--lib/rubygems/test_case.rb6
1 files changed, 5 insertions, 1 deletions
diff --git a/lib/rubygems/test_case.rb b/lib/rubygems/test_case.rb
index ff261f7816e..fb5f3008e2f 100644
--- a/lib/rubygems/test_case.rb
+++ b/lib/rubygems/test_case.rb
@@ -315,7 +315,11 @@ class Gem::TestCase < MiniTest::Unit::TestCase
def teardown
$LOAD_PATH.replace @orig_LOAD_PATH if @orig_LOAD_PATH
- RbConfig::CONFIG['BASERUBY'] = @orig_BASERUBY
+ if @orig_BASERUBY
+ RbConfig::CONFIG['BASERUBY'] = @orig_BASERUBY
+ else
+ RbConfig::CONFIG.delete('BASERUBY')
+ end
RbConfig::CONFIG['arch'] = @orig_arch
if defined? Gem::RemoteFetcher then