Added condition for divide by zero check

This commit is contained in:
Yadukrishnan 2024-04-10 22:43:46 +02:00
parent 443829bc4f
commit 0b456e3b4e
1 changed files with 1 additions and 1 deletions

View File

@ -94,7 +94,7 @@ public class ComplexNumberOperationsUnitTest {
Exception exception = Assertions.assertThrows(ArithmeticException.class, () -> {
complex1.divide(zero);
});
Assertions.assertEquals(exception.getMessage(), "Division by 0 is now allowed!");
Assertions.assertEquals(exception.getMessage(), "Division by 0 is not allowed!");
}
public boolean isSame(ComplexNumber result, ComplexNumber expected) {