aboutsummaryrefslogtreecommitdiffstats
path: root/test/ruby/test_range.rb
diff options
context:
space:
mode:
Diffstat (limited to 'test/ruby/test_range.rb')
-rw-r--r--test/ruby/test_range.rb4
1 files changed, 4 insertions, 0 deletions
diff --git a/test/ruby/test_range.rb b/test/ruby/test_range.rb
index 4df14539a9..800cee92cc 100644
--- a/test/ruby/test_range.rb
+++ b/test/ruby/test_range.rb
@@ -950,4 +950,8 @@ class TestRange < Test::Unit::TestCase
def test_beginless_range_iteration
assert_raise(TypeError) { (..1).each { } }
end
+
+ def test_count
+ assert_equal(Float::INFINITY, (1..).count)
+ end
end