ruby-changes:25932
From: naruse <ko1@a...>
Date: Thu, 29 Nov 2012 17:36:45 +0900 (JST)
Subject: [ruby-changes:25932] naruse:r37989 (trunk): * lib/rubygems.rb (Gem.load_yaml): return if Kernel#gem is not defined
naruse 2012-11-29 17:34:52 +0900 (Thu, 29 Nov 2012) New Revision: 37989 http://svn.ruby-lang.org/cgi-bin/viewvc.cgi?view=rev&revision=37989 Log: * lib/rubygems.rb (Gem.load_yaml): return if Kernel#gem is not defined yet. This causes crash if test-all requires libraries in a certain order. A simple reproducible code is ruby --disable-gem -e'require"yaml";require"minitest/autorun"' Modified files: trunk/ChangeLog trunk/lib/rubygems.rb Index: ChangeLog =================================================================== --- ChangeLog (revision 37988) +++ ChangeLog (revision 37989) @@ -1,3 +1,10 @@ +Thu Nov 29 17:31:53 2012 NARUSE, Yui <naruse@r...> + + * lib/rubygems.rb (Gem.load_yaml): return if Kernel#gem is not defined + yet. This causes crash if test-all requires libraries in a certain + order. A simple reproducible code is + ruby --disable-gem -e'require"yaml";require"minitest/autorun"' + Thu Nov 29 17:19:26 2012 Eric Hodel <drbrain@s...> * lib/tracer.rb: Updated to match removal of custom_require from @@ -34,7 +41,7 @@ * lib/rubygems/test_case.rb: Disable loading of keys and certificates outside rubygems or ruby tests as the files are not available (or - necessary). + necessary). Thu Nov 29 16:14:41 2012 Koichi Sasada <ko1@a...> Index: lib/rubygems.rb =================================================================== --- lib/rubygems.rb (revision 37988) +++ lib/rubygems.rb (revision 37989) @@ -536,6 +536,7 @@ def self.load_yaml return if @yaml_loaded + return unless defined?(gem) test_syck = ENV['TEST_SYCK'] -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/