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

Add BeforeEachTemplating callback #883

Closed
ctapobep opened this issue Jun 11, 2017 · 6 comments
Closed

Add BeforeEachTemplating callback #883

ctapobep opened this issue Jun 11, 2017 · 6 comments

Comments

@ctapobep
Copy link

Current BeforeEachCallback and BeforeTestExecutionCallback are invoked after ArgumentProvider finished. Would be either add more methods to the existing callbacks or to create a new callback that would run before the ArgumentProvider starts.

Rationale: in my extension I'd like to impact how the data is generated in the ArgumentProviders (I'm interested in @MethodSource in particular). So that it's possible to set the seed for randomization that happens in the @MethodSource.

@sbrannen
Copy link
Member

@nipafx
Copy link
Contributor

nipafx commented Jun 13, 2017

@ctapobep Would #853 cover your use case.

@ctapobep
Copy link
Author

I don't think so - I need a hook before argument providers are run.

@nipafx
Copy link
Contributor

nipafx commented Jun 15, 2017

Why not create your own @RandomMethodSource argument provider, then?

Regarding your proposal to modify existing callbacks: Note that argument providers are slightly separate from the rest of Jupiter because, strictly speaking, they are part of an extension (junit-jupiter-params). In my opinion this closes off the possibility to modify existing extension points to interact with them. On top of that, such a modification would also undermine the effort to keep extension points simple and focused.

This leaves your proposal to add a callback to providers that they call before resolution...

@stale
Copy link

stale bot commented May 13, 2021

This issue has been automatically marked as stale because it has not had recent activity. Given the limited bandwidth of the team, it will be automatically closed if no further activity occurs. Thank you for your contribution.

@stale stale bot added the status: stale label May 13, 2021
@stale
Copy link

stale bot commented Jun 3, 2021

This issue has been automatically closed due to inactivity. If you have a good use case for this feature, please feel free to reopen the issue.

@stale stale bot closed this as completed Jun 3, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants