commit | c876c0c189061564905594111e336f7e588666a0 | [log] [tgz] |
---|---|---|
author | aherbert <aherbert@apache.org> | Thu Apr 09 12:34:37 2020 +0100 |
committer | aherbert <aherbert@apache.org> | Thu Apr 09 12:34:37 2020 +0100 |
tree | c88905a4d8707e2b4537519be64f83c7cfd66844 | |
parent | 6cabdbc54d0af1976339e000217950a88b583e79 [diff] |
FractionTest: zero divide should be equal to Fraction.ZERO This relaxes the requirement that it is the same object as Fraction.ZERO.
diff --git a/commons-numbers-fraction/src/test/java/org/apache/commons/numbers/fraction/FractionTest.java b/commons-numbers-fraction/src/test/java/org/apache/commons/numbers/fraction/FractionTest.java index 931b4c5..5644c72 100644 --- a/commons-numbers-fraction/src/test/java/org/apache/commons/numbers/fraction/FractionTest.java +++ b/commons-numbers-fraction/src/test/java/org/apache/commons/numbers/fraction/FractionTest.java
@@ -314,7 +314,7 @@ Fraction f3 = Fraction.of(0, 5); Fraction f4 = Fraction.of(2, 7); Fraction f = f3.divide(f4); - Assertions.assertSame(Fraction.ZERO, f); + Assertions.assertEquals(Fraction.ZERO, f); final Fraction f5 = Fraction.of(Integer.MIN_VALUE, 1); Assertions.assertThrows(NullPointerException.class,