### Question:
Resolution { @Override public int hashCode() { final int prime = 31; int result = 1; result = prime * result + width; result = prime * result + height; result = prime * result + rate; return result; } 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 testHashCode() { final Resolution resolution = new Resolution(320, 240, 60); assertHashEquals(new Resolution(320, 240, 60), resolution); assertHashNotEquals(resolution, new Object()); assertHashNotEquals(resolution, new Resolution(100, 240, 60)); assertHashNotEquals(resolution, new Resolution(320, 100, 60)); assertHashNotEquals(resolution, new Resolution(320, 240, 30)); }