From 3c50c4d885455f61f9ba1220b881c157bcfc57f9 Mon Sep 17 00:00:00 2001 From: Luc Maisonobe Date: Thu, 2 Apr 2009 09:05:56 +0000 Subject: [PATCH] fixed a missing absolute value in a test threshold git-svn-id: https://svn.apache.org/repos/asf/commons/proper/math/trunk@761213 13f79535-47bb-0310-9956-ffa450edef68 --- .../commons/math/analysis/polynomials/PolynomialsUtilsTest.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/test/org/apache/commons/math/analysis/polynomials/PolynomialsUtilsTest.java b/src/test/org/apache/commons/math/analysis/polynomials/PolynomialsUtilsTest.java index e0529c765..83cc8f04b 100644 --- a/src/test/org/apache/commons/math/analysis/polynomials/PolynomialsUtilsTest.java +++ b/src/test/org/apache/commons/math/analysis/polynomials/PolynomialsUtilsTest.java @@ -191,7 +191,7 @@ public class PolynomialsUtilsTest extends TestCase { for (int i = 0; i < l40.length; ++i) { if (i % 2 == 0) { double ci = numerators[i / 2] / denominator; - assertEquals(ci, l40[i], ci * 1.0e-15); + assertEquals(ci, l40[i], Math.abs(ci) * 1.0e-15); } else { assertEquals(0.0, l40[i], 0.0); }