public void testEqualsNaN() { Complex realNaN = new Complex(Double.NaN, 0.0); Complex imaginaryNaN = new Complex(0.0, Double.NaN); Complex complexNaN = Complex.NaN; assertTrue(realNaN.equals(imaginaryNaN)); assertTrue(imaginaryNaN.equals(complexNaN)); assertTrue(realNaN.equals(complexNaN)); }
public boolean reallyAnimated() { return !animationStart.equals(animationEnd); }
public void testEqualsImaginaryDifference() { Complex x = new Complex(0.0, 0.0); Complex y = new Complex(0.0, 0.0 + Double.MIN_VALUE); assertFalse(x.equals(y)); }
public void testEqualsTrue() { Complex x = new Complex(3.0, 4.0); Complex y = new Complex(3.0, 4.0); assertTrue(x.equals(y)); }
public void testEqualsSame() { Complex x = new Complex(3.0, 4.0); assertTrue(x.equals(x)); }
public void testEqualsClass() { Complex x = new Complex(3.0, 4.0); assertFalse(x.equals(this)); }
public void testEqualsNull() { Complex x = new Complex(3.0, 4.0); assertFalse(x.equals(null)); }