mirror of
https://github.com/ruby/ruby.git
synced 2022-11-09 12:17:21 -05:00
* test/ruby/test_numeric.rb (test_step): Use Integer::FIXNUM_MAX.
git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@54876 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
76be3f22c7
commit
af97057c4d
2 changed files with 5 additions and 2 deletions
|
@ -1,3 +1,7 @@
|
|||
Mon May 2 01:27:59 2016 Tanaka Akira <akr@fsij.org>
|
||||
|
||||
* test/ruby/test_numeric.rb (test_step): Use Integer::FIXNUM_MAX.
|
||||
|
||||
Mon May 2 01:15:01 2016 Tanaka Akira <akr@fsij.org>
|
||||
|
||||
* test/ruby/test_module.rb (test_name): Use Integer instead of Fixnum.
|
||||
|
|
|
@ -252,8 +252,7 @@ class TestNumeric < Test::Unit::TestCase
|
|||
end
|
||||
|
||||
def test_step
|
||||
i, bignum = 32, 1 << 30
|
||||
bignum <<= (i <<= 1) - 32 until bignum.is_a?(Bignum)
|
||||
bignum = Integer::FIXNUM_MAX + 1
|
||||
assert_raise(ArgumentError) { 1.step(10, 1, 0) { } }
|
||||
assert_raise(ArgumentError) { 1.step(10, 1, 0).size }
|
||||
assert_raise(ArgumentError) { 1.step(10, 0) { } }
|
||||
|
|
Loading…
Reference in a new issue