Details
-
Bug
-
Status: Open
-
Major
-
Resolution: Unresolved
-
3.9
-
None
-
Ubuntu 18.04
JDK 1.8.0_221
Commons Lang 3.9-RC2
JUnit 5.4
Description
EqualsBuilder.reflectionEquals() does not hold transitivity when comparing two subclasses extending a common superclass. For example:
Given that both class D and E are subclasses of class C, C == D and C == E should imply D == E. However EqualsBuilder.reflectionEquals(D, E) returns false when both EqualsBuilder.reflectionEquals(C, D) and EqualsBuilder.reflectionEquals(C, E) return true.
A junit test is provided as attachment.