### Question:
AssetExternalIdentifier extends AssetReferenceable { @Override public boolean equals(Object objectToCompare) { if (this == objectToCompare) { return true; } if (!(objectToCompare instanceof AssetExternalIdentifier)) { return false; } if (!super.equals(objectToCompare)) { return false; } AssetExternalIdentifier that = (AssetExternalIdentifier) objectToCompare; return Objects.equals(getExternalIdentifierBean(), that.getExternalIdentifierBean()); } AssetExternalIdentifier(ExternalIdentifier   externalIdentifierBean);  AssetExternalIdentifier(AssetDescriptor      parentAsset,
                                   ExternalIdentifier   externalIdentifierBean);  AssetExternalIdentifier(AssetDescriptor parentAsset, AssetExternalIdentifier templateExternalIdentifier); String getIdentifier(); String getDescription(); String getUsage(); String getSource(); KeyPattern getKeyPattern(); AssetReferenceable getScope(); String getScopeDescription(); @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())); AssetExternalIdentifier sameObject = getTestObject(); assertTrue(sameObject.equals(sameObject)); assertFalse(getTestObject().equals(getDifferentObject())); assertFalse(getTestObject().equals(getAnotherDifferentObject())); }