i came across one situation when JRuby was behaving a little different than MRI and gave me a BigDecimal where MRI used to return a Float. It did not really matter for the project, but using Wrong::CloseTo in my assertion did not work, because only Float and Fixnum could respond to 'close_to?'.
So here's a tiny fix for that, just including CloseTo in Numeric.
Love the name, 'wrong'.
Hi
i came across one situation when JRuby was behaving a little different than MRI and gave me a BigDecimal where MRI used to return a Float. It did not really matter for the project, but using Wrong::CloseTo in my assertion did not work, because only Float and Fixnum could respond to 'close_to?'.
So here's a tiny fix for that, just including CloseTo in Numeric. Love the name, 'wrong'.