assertTrue(ElementHelper.areEqual(mockPropertyA, mockPropertyB));
}
@Test
public void shouldDeterminePropertiesAreNotEqualWhenElementsAreDifferent() {
final Property mockPropertyA = mock(Property.class);
final Property mockPropertyB = mock(Property.class);
final Element mockElement = mock(Element.class);
final Element mockElementDifferent = mock(Element.class);
when(mockPropertyA.isPresent()).thenReturn(true);
when(mockPropertyB.isPresent()).thenReturn(true);
when(mockPropertyA.element()).thenReturn(mockElement);
when(mockPropertyB.element()).thenReturn(mockElementDifferent);
when(mockPropertyA.key()).thenReturn("k");
when(mockPropertyB.key()).thenReturn("k");
when(mockPropertyA.value()).thenReturn("v");
when(mockPropertyB.value()).thenReturn("v");
assertFalse(ElementHelper.areEqual(mockPropertyA, mockPropertyB));
}