-
Notifications
You must be signed in to change notification settings - Fork 2.7k
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
Support @InjectSpy on javax.inject.Singleton classes #30608
Comments
/cc @geoand (testing) |
I solved my problem by creating a wrapper bean |
geoand
added a commit
to geoand/quarkus
that referenced
this issue
Jan 26, 2023
The same way we support convertScopes on @InjectMock we can support it on @InjectSpy as well. Closes: quarkusio#30608
geoand
added a commit
to geoand/quarkus
that referenced
this issue
Jan 26, 2023
The same way we support convertScopes on @InjectMock we can support it on @InjectSpy as well. Closes: quarkusio#30608
Good idea! #30623 will take care of it |
geoand
added a commit
that referenced
this issue
Jan 26, 2023
Introduce convertScopes to `@InjectSpy`
thanks for the quick fix @geoand ! |
YW |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Description
Currently, if I try to
@InjectSpy
ajavax.inject.Singleton
class, likejavax.transaction.TransactionManager
, I get the error:By checking this issue: #8983, it seems that
@InjectMock
has a paramconvertScopes
that addresses this issue. Could this also work onInjectSpy
?I wanted to do something like this in my tests:
Implementation ideas
No response
The text was updated successfully, but these errors were encountered: