-
Notifications
You must be signed in to change notification settings - Fork 3k
Properly rest mocks (again) #47214
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
Properly rest mocks (again) #47214
Conversation
Follows up on: quarkusio#47181
And we still avoid the memory leaks we were trying to fix? |
Should we drop the mocks from |
Now we are trying to avoid flaky tests, we don't have any new reports of memory leaks |
Yes but my understanding is that we were calling |
And I'm not very familiar with this so it might be invalid but I'm surprised we keep a reference to all mocks in a static field of |
This comment has been minimized.
This comment has been minimized.
I really don't remember.
Maybe, but that would require more time than I have this week to figure out |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's not merge this right away, I will do some archeology.
Also remove mocks from MockitoMocksTracker after the whole test is executed.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I pushed an additional commit that seems to work, while still clearing the inline mocks.
Not completely sure that I did nested tests right but I added a test and it seems to work.
Thanks a lot for taking a deep look! |
Status for workflow
|
Follows up on: #47181.
This should fix the flaky tests we've been seeing on
PerClassSpyTest
P.S. If #47181 is backported, then this needs to be as well