- Notifications
You must be signed in to change notification settings - Fork560
Create a single LauncherSession for invocations of JUnitPlatformProvider#863
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Create a single LauncherSession for invocations of JUnitPlatformProvider#863
Uh oh!
There was an error while loading.Please reload this page.
Conversation
Prior to this commit, `JUnitPlatformProvider` created multiple`LauncherSessions` for some executions, for example when `forkTestSet`was `null` or when rerunning failed tests. This caused registered`LauncherSessionListeners` registered via `ServiceLoader` on the JUnitPlatform to be called multiple times. As they are intended to set up andtear down resources, this had the potential of unnecessarily slowingdown test execution.
Bukama commentedJul 3, 2025
Hey@marcphilipp Thanks for the PR! Would you call this a bugfix (as not intended to use this way) or enhancement? |
marcphilipp commentedJul 3, 2025
I think it's not strictly a bug so I would call it an enhancement. 🙂 |
olamy commentedJul 4, 2025
Looks like an excellent change. Thanks for this. |
bfa3cca intoapache:masterUh oh!
There was an error while loading.Please reload this page.
@olamy The PR can't be associated to a milestone, because there are multiple open milestones. Please add the text "branch: master" to the description to the milestone where this PR belongs to. |
Prior to this commit,
JUnitPlatformProvidercreated multipleLauncherSessionsfor some executions, for example whenforkTestSetwasnullor when rerunning failed tests. This caused registeredLauncherSessionListenersregistered viaServiceLoaderon the JUnit Platform to be called multiple times. As they are intended to set up and tear down resources, this had the potential of unnecessarily slowing down test execution.Following this checklist to help us incorporate your
contribution quickly and easily:
mvn clean installto make sure basic checks pass. A more thorough check willbe performed on your pull request automatically.
mvn -Prun-its clean install).If your pull request is about ~20 lines of code you don't need to sign an
Individual Contributor License Agreement if you are unsure
please ask on the developers list.
To make clear that you license your contribution under
theApache License Version 2.0, January 2004
you have to acknowledge this by using the following check-box.
I hereby declare this contribution to be licenced under theApache License Version 2.0, January 2004
In any other case, please file anApache Individual Contributor License Agreement.