Are we able to come up with a better way of comparing float32 and double than the compare() method? Below is a screenshot from one unit tests that fails because it seems unable to properly handle minor differences in values (due to numerical truncations and errors):
Also, when trying to step inside compare() it is impossible to see what's actually going on, as illustrated here:
Having seen Catch used elsewhere recently, I'm wondering if it would be a good idea to use Catch for Jamoma2 unit tests?
Are we able to come up with a better way of comparing
float32
anddouble
than thecompare()
method? Below is a screenshot from one unit tests that fails because it seems unable to properly handle minor differences in values (due to numerical truncations and errors):Also, when trying to step inside compare() it is impossible to see what's actually going on, as illustrated here:
Having seen Catch used elsewhere recently, I'm wondering if it would be a good idea to use Catch for Jamoma2 unit tests?