We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 0458acc commit d2c7dd7Copy full SHA for d2c7dd7
spec/ruby/core/range/count_spec.rb
@@ -1,17 +1,11 @@
1
require_relative '../../spec_helper'
2
3
describe "Range#count" do
4
- ruby_version_is "2.6" do
5
- it "returns Infinity for endless ranges without arguments or blocks" do
6
- inf = Float::INFINITY
7
- eval("('a'...)").count.should == inf
8
- eval("(7..)").count.should == inf
9
- end
10
11
-
12
ruby_version_is "2.7" do
13
it "returns Infinity for beginless ranges without arguments or blocks" do
14
inf = Float::INFINITY
+ eval("('a'...)").count.should == inf
+ eval("(7..)").count.should == inf
15
eval("(...'a')").count.should == inf
16
eval("(...nil)").count.should == inf
17
eval("(..10.0)").count.should == inf
0 commit comments