### Question:
Resolution { @Override public boolean equals(Object object) { if (this == object) { return true; } if (object == null || getClass() != object.getClass()) { return false; } final Resolution other = (Resolution) object; return width == other.width && height == other.height && rate == other.rate; } Resolution(int width, int height, int rate); Resolution get2x(); Resolution get3x(); Resolution get4x(); Resolution getScaled(double factorX, double factorY); int getWidth(); int getHeight(); int getRate(); @Override int hashCode(); @Override boolean equals(Object object); @Override String toString();  }### Answer:
@Test void testEquals() { final Resolution resolution = new Resolution(320, 240, 60); assertEquals(resolution, resolution); assertEquals(new Resolution(320, 240, 60), resolution); assertNotEquals(resolution, null); assertNotEquals(resolution, new Object()); assertNotEquals(resolution, new Resolution(100, 240, 60)); assertNotEquals(resolution, new Resolution(320, 100, 60)); assertNotEquals(resolution, new Resolution(320, 240, 30)); }