-
-
Notifications
You must be signed in to change notification settings - Fork 683
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Recursive comparison uses equals
on root object when useOverriddenEquals
is enabled
#3320
Comments
Thanks for reporting it, @austinarbor-wk! |
Possibly related to 0eb44cc and still unsure if the behavior in version 3.24.2 was correct, though. What should be the expected behavior when I feel Any thoughts @joel-costigliola? |
I think my expectation from the original code sample above based on the javadoc is that the comparison would be equivalent to the compound assertion of assertThat(a1.name).isEqualTo(a2.name)
assertThat(a1.b).isEqualTo(a2.b) Is my understanding incorrect? |
Do I understand correctly that you'd like to use the overridden |
I would expect both compared fields to be compared with equals, compared fields limits the comparison to the specified fields and I'll have a look at the issue this week. |
My expectation is how @joel-costigliola describes |
Alright, the issue is that the code that decides whether to use the overridden |
equals
on root object when useOverriddenEquals
is enabled
Thank you for the assertj project, it makes reading & writing tests enjoyable. I am curious if there is a timeline for 3.25.2 release with the fix for this issue. We have had to roll back a number of projects to 3.24.2 due to tests using recursive comparison timing out and failing. Thank you! |
Thank you for the 3.25.2 release! I ran some quick tests using 3.25.2 and it has resolved the issues we were encountering with |
Confirmed 3.25.2 resolves the issues we were experiencing as well, thanks! |
Thanks for the feedback, appreciated! |
Describe the bug
It appears that 3.25.0 has changed behavior of recursive comparison
The below test succeeds in 3.24.2 but fails in 3.25.0
The text was updated successfully, but these errors were encountered: