-
Notifications
You must be signed in to change notification settings - Fork 1k
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
Add a way for 3rd party to intercept method param injection #1164
Comments
I think the brand new JUnit 5 extension model can be a good source of inspiration. The only thing missing in JUnit 5 is a way for a 3rd-party library to automatically register those extensions, without users having to manually add "@ExtendWith" annotations to their test classes. TestNG already has a set of extension interfaces (IExecutionListener, for example, which JMockit implements), but none similar to JUnit's ParameterResolver interface. I imagine something like this could be added. |
I would like to propose we should think not just about Following is a preliminary idea on generically supporting/exposing integrations:
Metaphor: TestNG is a mothership and other products are pods. Pods dock in the mothership and offer bunch of features. Features get coupled or coupling waits of another features (via same pod or another) or rejected as is retracted. Once the couplings are in place mothership can engage or disengage to carryout proper functioning and course correction. Above is just a rough outline I hope gets enriched via discussion. |
I like the vision but it can be done by steps and method argument injection is the perfect candidate for the first step. And currently, listeners are a good way for 3rd party extensions. |
From jmockit/jmockit1#337
It should work with and without dataprovider.
@rliesenfeld Any wishes on a future provided API?
@nitinverma is open to participate to the integration as he already made good job on param injection.
The text was updated successfully, but these errors were encountered: