/**
* Check that the equals() method can distinguish all fields.
*/
public void testEquals() {
ColorBar c1 = new ColorBar("Test");
ColorBar c2 = new ColorBar("Test");
assertEquals(c1, c2);
c1.setAxis(new NumberAxis("Axis 1"));
assertTrue(!c1.equals(c2));
c2.setAxis(new NumberAxis("Axis 1"));
assertTrue(c1.equals(c2));
c1.setColorPalette(new GreyPalette());
assertTrue(!c1.equals(c2));
c2.setColorPalette(new GreyPalette());
assertTrue(c1.equals(c2));
}