### Question:
VirtualConnectionProperties extends ConnectionProperties { @Override public boolean equals(Object objectToCompare) { if (this == objectToCompare) { return true; } if (!(objectToCompare instanceof VirtualConnectionProperties)) { return false; } if (!super.equals(objectToCompare)) { return false; } VirtualConnectionProperties that = (VirtualConnectionProperties) objectToCompare; return Objects.equals(getConnectionBean(), that.getConnectionBean()); } VirtualConnectionProperties(VirtualConnection connectionBean);  VirtualConnectionProperties(AssetDescriptor parentAsset,
                                       VirtualConnection connectionBean);  VirtualConnectionProperties(VirtualConnectionProperties templateConnection);  VirtualConnectionProperties(AssetDescriptor parentAsset, VirtualConnectionProperties templateConnection); List<EmbeddedConnectionProperties> getEmbeddedConnections(); String getConnectionName(); String getDescription(); ConnectorTypeProperties getConnectorType(); EndpointProperties getEndpoint(); @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())); VirtualConnectionProperties sameObject = getTestObject(); assertTrue(sameObject.equals(sameObject)); assertFalse(getTestObject().equals(getDifferentObject())); assertFalse(getTestObject().equals(getAnotherDifferentObject())); }