### Question:
AssetNote extends AssetReferenceable { @Override public boolean equals(Object objectToCompare) { if (this == objectToCompare) { return true; } if (!(objectToCompare instanceof AssetNote)) { return false; } if (!super.equals(objectToCompare)) { return false; } AssetNote that = (AssetNote) objectToCompare; return Objects.equals(getNoteBean(), that.getNoteBean()); } AssetNote(Note  noteBean);  AssetNote(AssetDescriptor parentAsset,
                     Note            noteBean);  AssetNote(AssetDescriptor parentAsset, AssetNote templateNote); String getText(); Date getLastUpdate(); String getUser(); @Override String toString(); @Override boolean equals(Object objectToCompare);  }### Answer:
@Test public void testEquals() { assertFalse(getTestObject().equals(null)); assertFalse(getTestObject().equals("DummyString")); assertTrue(getTestObject().equals(getTestObject())); AssetNote sameObject = getTestObject(); assertTrue(sameObject.equals(sameObject)); assertFalse(getTestObject().equals(getDifferentObject())); assertFalse(getTestObject().equals(getAnotherDifferentObject())); }