ruby-changes:62108
From: Yusuke <ko1@a...>
Date: Fri, 3 Jul 2020 11:47:24 +0900 (JST)
Subject: [ruby-changes:62108] 1e039474a2 (master): test/json/json_fixtures_test.rb: Prevent an "out of range" warning
https://git.ruby-lang.org/ruby.git/commit/?id=1e039474a2 From 1e039474a2d55bdc7cfc5a01b4d8cf00ae446a76 Mon Sep 17 00:00:00 2001 From: Yusuke Endoh <mame@r...> Date: Fri, 3 Jul 2020 11:45:58 +0900 Subject: test/json/json_fixtures_test.rb: Prevent an "out of range" warning ``` /home/mame/work/ruby/.ext/common/json/common.rb:263: warning: Float 23456789012E666 out of range ``` diff --git a/test/json/json_fixtures_test.rb b/test/json/json_fixtures_test.rb index b2a1ec8..845abb4 100644 --- a/test/json/json_fixtures_test.rb +++ b/test/json/json_fixtures_test.rb @@ -10,6 +10,7 @@ class JSONFixturesTest < Test::Unit::TestCase https://github.com/ruby/ruby/blob/trunk/test/json/json_fixtures_test.rb#L10 end def test_passing + verbose_bak, $VERBOSE = $VERBOSE, nil for name, source in @passed begin assert JSON.parse(source), @@ -19,6 +20,8 @@ class JSONFixturesTest < Test::Unit::TestCase https://github.com/ruby/ruby/blob/trunk/test/json/json_fixtures_test.rb#L20 raise e end end + ensure + $VERBOSE = verbose_bak end def test_failing -- cgit v0.10.2 -- ML: ruby-changes@q... Info: http://www.atdot.net/~ko1/quickml/