1
0
Fork 0
mirror of https://github.com/ruby/ruby.git synced 2022-11-09 12:17:21 -05:00

Fix 33906: remove JSON::Ext::Generator::GeneratorMethods::String.

git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@33910 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
naruse 2011-11-30 15:19:02 +00:00
parent f6f4534382
commit 4c5c26cec1

View file

@ -203,6 +203,7 @@ class TestModule < Test::Unit::TestCase
ancestors = Object.ancestors ancestors = Object.ancestors
mixins = ancestors - [Object, Kernel, BasicObject] mixins = ancestors - [Object, Kernel, BasicObject]
mixins << JSON::Ext::Generator::GeneratorMethods::String if defined?(JSON::Ext::Generator::GeneratorMethods::String)
assert_equal([Object, Kernel, BasicObject], ancestors - mixins) assert_equal([Object, Kernel, BasicObject], ancestors - mixins)
assert_equal([String, Comparable, Object, Kernel, BasicObject], String.ancestors - mixins) assert_equal([String, Comparable, Object, Kernel, BasicObject], String.ancestors - mixins)
end end
@ -263,6 +264,7 @@ class TestModule < Test::Unit::TestCase
assert_equal([Mixin], User.included_modules) assert_equal([Mixin], User.included_modules)
mixins = Object.included_modules - [Kernel] mixins = Object.included_modules - [Kernel]
mixins << JSON::Ext::Generator::GeneratorMethods::String if defined?(JSON::Ext::Generator::GeneratorMethods::String)
assert_equal([Kernel], Object.included_modules - mixins) assert_equal([Kernel], Object.included_modules - mixins)
assert_equal([Comparable, Kernel], String.included_modules - mixins) assert_equal([Comparable, Kernel], String.included_modules - mixins)
end end