mirror of
https://github.com/ruby/ruby.git
synced 2025-08-25 22:14:37 +02:00
* numeric.c (int_dotimes): Support for Integer#times.size
[Feature #6636] git-svn-id: svn+ssh://ci.ruby-lang.org/ruby/trunk@37519 b2dd03c8-39d4-4d8f-98ff-823fe69b080e
This commit is contained in:
parent
c2dc0dc1ce
commit
3a4eb4dd39
2 changed files with 14 additions and 1 deletions
|
@ -506,6 +506,7 @@ class TestEnumerator < Test::Unit::TestCase
|
|||
|
||||
def test_size_for_loops
|
||||
assert_equal Float::INFINITY, loop.size
|
||||
assert_equal 42, 42.times.size
|
||||
end
|
||||
|
||||
def test_size_for_each_slice
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue