This is an automated email from the ASF dual-hosted git repository. asf-gitbox-commits pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/commons-numbers.git
commit feb807f7ec6eab7a86875f25e6975769f7571424 Author: Alex Herbert <[email protected]> AuthorDate: Wed Oct 21 14:57:56 2026 +0100 Assert non-finite result for trigamma --- .../test/java/org/apache/commons/numbers/gamma/TrigammaTest.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/commons-numbers-gamma/src/test/java/org/apache/commons/numbers/gamma/TrigammaTest.java b/commons-numbers-gamma/src/test/java/org/apache/commons/numbers/gamma/TrigammaTest.java index 3871f509..22ceae6e 100644 --- a/commons-numbers-gamma/src/test/java/org/apache/commons/numbers/gamma/TrigammaTest.java +++ b/commons-numbers-gamma/src/test/java/org/apache/commons/numbers/gamma/TrigammaTest.java @@ -105,14 +105,14 @@ class TrigammaTest { @Test void testTrigammaZero() { - Assertions.assertEquals(Double.POSITIVE_INFINITY, Trigamma.value(0), 0d); + Assertions.assertEquals(Double.POSITIVE_INFINITY, Trigamma.value(0)); } @Test void testTrigammaNonRealArgs() { - Assertions.assertTrue(Double.isNaN(Trigamma.value(Double.NaN))); - Assertions.assertTrue(Double.isInfinite(Trigamma.value(Double.POSITIVE_INFINITY))); - Assertions.assertTrue(Double.isInfinite(Trigamma.value(Double.NEGATIVE_INFINITY))); + Assertions.assertEquals(Double.NaN, Trigamma.value(Double.NaN)); + Assertions.assertEquals(Double.POSITIVE_INFINITY, Trigamma.value(Double.POSITIVE_INFINITY)); + Assertions.assertEquals(Double.NEGATIVE_INFINITY, Trigamma.value(Double.NEGATIVE_INFINITY)); } }
