Reflexivity means to turn back on itself… Every object must equal itself.
We can use this idea for testing.
boolean testEqualsIsReflexive(Object obj) {return obj.equals(obj);}To break, just return false
Reflexivity means to turn back on itself… Every object must equal itself.
We can use this idea for testing.
boolean testEqualsIsReflexive(Object obj) {return obj.equals(obj);}To break, just return false