Skip to content
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

lombock generated equals() not working as it did anymore #1724

Closed
metas-ts opened this issue Jun 9, 2018 · 3 comments
Closed

lombock generated equals() not working as it did anymore #1724

metas-ts opened this issue Jun 9, 2018 · 3 comments

Comments

@metas-ts
Copy link

metas-ts commented Jun 9, 2018

Hi guys
the following worked with lombok 1.16.16, but not with 1.16.22.

here are the failing test's reports:

here is the commit that fixed the test for 1.16.22
metasfresh/metasfresh@e2393a6 (see line 48)

Here is the "fixed" AttributesKey file: https://github.com/metasfresh/metasfresh/blob/e2393a63eaa0830f71dc48de865f3210a71e69e4/de.metas.material/event/src/main/java/de/metas/material/event/commons/AttributesKey.java

Here is the test case
https://github.com/metasfresh/metasfresh/blob/e2393a63eaa0830f71dc48de865f3210a71e69e4/de.metas.material/event/src/test/java/de/metas/material/event/commons/AttributesKeyTest.java

As a side note, I think I have other cases where @EqualsAndHashCode(doNotUseGetters = true) didn't help me out, e.g. this test failure: @EqualsAndHashCode(doNotUseGetters = true) ..at least not in 1.16.22, but I'm not definitive about 1.18.0

@potentcocktail
Copy link

I've noticed that @EqualsAndHashCode doesn't auto-exclude transient fields any more, ever since 1.16.22, even though the documentation says it does.

@rspilker
Copy link
Collaborator

Oops. Looking into it now.

@rspilker
Copy link
Collaborator

Thanks! I've also added some tests to prevent similar problems in the future.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants