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

Reset the TCCL for each test #7106

Merged
merged 1 commit into from
Feb 10, 2020
Merged

Conversation

stuartwdouglas
Copy link
Member

This makes sure the correct TCCL is set if there is a mix
of @QuarkusTest and normal tests

This makes sure the correct TCCL is set if there is a mix
of @QuarkusTest and normal tests
@aloubyansky
Copy link
Member

Are beforeAll/afterAll called more than once in this case?

@stuartwdouglas
Copy link
Member Author

The are called before and after every @QuarkusTest test class. The issue is that if we don't reset it in between classes and the test suite contains non-quarkus tests (e.g. tests with mocks) then these tests will run with the wrong class loader. This will break Mockito.

@aloubyansky aloubyansky added this to the 1.3.0 milestone Feb 10, 2020
@aloubyansky aloubyansky merged commit dac954c into quarkusio:master Feb 10, 2020
@sean-scott-lr
Copy link

@stuartwdouglas Thank you, this does fix my mockito error.

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

Successfully merging this pull request may close these issues.

3 participants