This is needed for the future parser which actually treats numbers as
numbers and strings as strings. With this patch you can use range(1,5)
instead of having to quote them like range('1','5').
end
# Check whether we have integer value if so then make it so ...
- if start.match(/^\d+$/)
+ if start.to_s.match(/^\d+$/)
start = start.to_i
stop = stop.to_i
else
expect(scope.function_range(["00", "10"])).to eq expected
end
end
+
+ describe 'with a numeric range' do
+ it "returns a range of numbers" do
+ expected = (1..10).to_a
+ expect(scope.function_range([1,10])).to eq expected
+ end
+ end
end