| Modifier and Type | Field and Description |
|---|---|
private java.util.function.Supplier<java.util.List<LauncherInterceptor>> |
interceptorFactory |
private java.util.function.Supplier<Launcher> |
launcherSupplier |
private LauncherListenerRegistry |
listenerRegistry |
private java.util.function.Supplier<LauncherSessionListener> |
sessionListenerSupplier |
| Constructor and Description |
|---|
SessionPerRequestLauncher(java.util.function.Supplier<Launcher> launcherSupplier,
java.util.function.Supplier<LauncherSessionListener> sessionListenerSupplier,
java.util.function.Supplier<java.util.List<LauncherInterceptor>> interceptorFactory) |
| Modifier and Type | Method and Description |
|---|---|
private LauncherSession |
createSession() |
TestPlan |
discover(LauncherDiscoveryRequest launcherDiscoveryRequest)
Discover tests and build a
TestPlan according to the supplied
LauncherDiscoveryRequest by querying all registered engines and
collecting their results. |
void |
execute(LauncherDiscoveryRequest launcherDiscoveryRequest,
TestExecutionListener... listeners)
Execute a
TestPlan which is built according to the supplied
LauncherDiscoveryRequest by querying all registered engines and
collecting their results, and notify
registered listeners about
the progress and results of the execution. |
void |
execute(TestPlan testPlan,
TestExecutionListener... listeners)
Execute the supplied
TestPlan and notify
registered listeners about
the progress and results of the execution. |
void |
registerLauncherDiscoveryListeners(LauncherDiscoveryListener... listeners)
Register one or more listeners for test discovery.
|
void |
registerTestExecutionListeners(TestExecutionListener... listeners)
Register one or more listeners for test execution.
|
private final LauncherListenerRegistry listenerRegistry
private final java.util.function.Supplier<Launcher> launcherSupplier
private final java.util.function.Supplier<LauncherSessionListener> sessionListenerSupplier
private final java.util.function.Supplier<java.util.List<LauncherInterceptor>> interceptorFactory
SessionPerRequestLauncher(java.util.function.Supplier<Launcher> launcherSupplier, java.util.function.Supplier<LauncherSessionListener> sessionListenerSupplier, java.util.function.Supplier<java.util.List<LauncherInterceptor>> interceptorFactory)
public void registerLauncherDiscoveryListeners(LauncherDiscoveryListener... listeners)
LauncherregisterLauncherDiscoveryListeners in interface Launcherlisteners - the listeners to be notified of test discovery events;
never null or emptypublic void registerTestExecutionListeners(TestExecutionListener... listeners)
LauncherregisterTestExecutionListeners in interface Launcherlisteners - the listeners to be notified of test execution events;
never null or emptypublic TestPlan discover(LauncherDiscoveryRequest launcherDiscoveryRequest)
LauncherTestPlan according to the supplied
LauncherDiscoveryRequest by querying all registered engines and
collecting their results.discover in interface LauncherlauncherDiscoveryRequest - the launcher discovery request; never
nullTestPlan that contains all resolved
identifiers from all registered enginespublic void execute(LauncherDiscoveryRequest launcherDiscoveryRequest, TestExecutionListener... listeners)
LauncherTestPlan which is built according to the supplied
LauncherDiscoveryRequest by querying all registered engines and
collecting their results, and notify
registered listeners about
the progress and results of the execution.
Supplied test execution listeners are registered in addition to already registered listeners but only for the supplied launcher discovery request.
public void execute(TestPlan testPlan, TestExecutionListener... listeners)
LauncherTestPlan and notify
registered listeners about
the progress and results of the execution.
Supplied test execution listeners are registered in addition to already registered listeners but only for the execution of the supplied test plan.
private LauncherSession createSession()