From the failing CPAN test report, the failing test seems to be this line number 37 in 01-openai.t:
is( $comp_pass1, 1, "Compare got $comp_pass1");
As a matter of style, I find it clearer to use the explicit cmp_ok for these types of tests (see also this perlmaven article).
Without fully understanding your module, it looks like a simple floating point rounding error; the normal way to deal with these is to introduce an epsilon value, as noted in Test::Number::Delta:
At some point or another, most programmers find they need to compare floating-point numbers for equality. The typical idiom is to test if the absolute value of the difference of the numbers is within a desired tolerance, usually called epsilon.
👁️🍾👍🦟
In reply to Re: Outlier test fail
by eyepopslikeamosquito
in thread Outlier test fail
by Bod
For: | Use: | ||
& | & | ||
< | < | ||
> | > | ||
[ | [ | ||
] | ] |