-
-
Notifications
You must be signed in to change notification settings - Fork 154
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
Set mock instance of interface into typed properties #1804
Labels
Comments
I think this is related to #650 |
@theofidry in what way? I imagine this as a new mutator. |
It will be caught by https://github.com/Roave/infection-static-analysis-plugin, and actually related to #1323 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Is your feature request related to a problem? Please describe.
A user has a class like so
Describe the solution you'd like
The user is typing an interface, but actually expecting the specific implementation to be available. Static analysis notices this when used.
A new mutator might set this property to a mocked interface which does the absolute minimum to match the interface, it would mean any reliance on the specific implementation would fail.
Describe alternatives you've considered
Incorporate static analysis output in some way instead?
Additional context
User claims "code works, tests work" and is wondering what is static analysis on about here.
The text was updated successfully, but these errors were encountered: