зеркало из https://github.com/github/ruby.git
json_generator_test.rb: no Bignum
* test/json/json_generator_test.rb (test_broken_bignum): get rid of use of Bignum, obsolete name. git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@56126 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
Родитель
646c53895f
Коммит
7f6410f02d
|
@ -277,12 +277,13 @@ EOT
|
|||
if defined?(JSON::Ext::Generator)
|
||||
def test_broken_bignum # [ruby-core:38867]
|
||||
pid = fork do
|
||||
Bignum.class_eval do
|
||||
x = 1 << 64
|
||||
x.class.class_eval do
|
||||
def to_s
|
||||
end
|
||||
end
|
||||
begin
|
||||
JSON::Ext::Generator::State.new.generate(1<<64)
|
||||
JSON::Ext::Generator::State.new.generate(x)
|
||||
exit 1
|
||||
rescue TypeError
|
||||
exit 0
|
||||
|
|
Загрузка…
Ссылка в новой задаче