Sha256: 300e478bb9a46de287e123d77b9826eccd34c159f5b90866dc2b40d8ade6db82
Contents?: true
Size: 476 Bytes
Versions: 51
Compression:
Stored size: 476 Bytes
Contents
class Range def self.at_least(minimum_value) Range.new(minimum_value, infinite) end def self.at_most(maximum_value) Range.new(-infinite, maximum_value, false) end def self.infinite 1/0.0 end def mocha_inspect if first.respond_to?(:to_f) and first.to_f.infinite? then return "at most #{last}" elsif last.respond_to?(:to_f) and last.to_f.infinite? then return "at least #{first}" else to_s end end end
Version data entries
51 entries across 51 versions & 4 rubygems