Attempt to fix floating point test failure
The previous behavior depending on exact float values, it seemed to work OK on amd64 and i386, but other CI platforms are experiencing non-deterministic test failures with it. Relax test slightly to hopefully pass on such platforms.
This commit is contained in:
parent
9bb76201dd
commit
fd65ef2a5a
@ -898,7 +898,7 @@ class TestFloat < Test::Unit::TestCase
|
||||
a = rand
|
||||
b = a+rand*1000
|
||||
s = (b - a) / 10
|
||||
b = a + s*10
|
||||
b = a + s*9.999999
|
||||
seq = (a...b).step(s)
|
||||
assert_equal(10, seq.to_a.length, seq.inspect)
|
||||
end
|
||||
|
Loading…
x
Reference in New Issue
Block a user