Package org.junit.platform.launcher.core
Class LauncherConfig.Builder
- java.lang.Object
-
- org.junit.platform.launcher.core.LauncherConfig.Builder
-
- Enclosing interface:
- LauncherConfig
public static class LauncherConfig.Builder extends Object
Builder API forLauncherConfig
.
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description LauncherConfig.Builder
addTestEngines(TestEngine... engines)
Add all of the suppliedengines
to the configuration.LauncherConfig.Builder
addTestExecutionListeners(TestExecutionListener... listeners)
Add all of the suppliedlisteners
to the configuration.LauncherConfig
build()
Build theLauncherConfig
that has been configured via this builder.LauncherConfig.Builder
enableTestEngineAutoRegistration(boolean enabled)
Configure the auto-registration flag for test engines.LauncherConfig.Builder
enableTestExecutionListenerAutoRegistration(boolean enabled)
Configure the auto-registration flag for test execution listeners.
-
-
-
Method Detail
-
enableTestExecutionListenerAutoRegistration
public LauncherConfig.Builder enableTestExecutionListenerAutoRegistration(boolean enabled)
Configure the auto-registration flag for test execution listeners.Defaults to
true
.- Parameters:
enabled
-true
if test execution listeners should be automatically registered- Returns:
- this builder for method chaining
-
enableTestEngineAutoRegistration
public LauncherConfig.Builder enableTestEngineAutoRegistration(boolean enabled)
Configure the auto-registration flag for test engines.Defaults to
true
.- Parameters:
enabled
-true
if test engines should be automatically registered- Returns:
- this builder for method chaining
-
addTestEngines
public LauncherConfig.Builder addTestEngines(TestEngine... engines)
Add all of the suppliedengines
to the configuration.- Parameters:
engines
- additional test engines to register; nevernull
or containingnull
- Returns:
- this builder for method chaining
-
addTestExecutionListeners
public LauncherConfig.Builder addTestExecutionListeners(TestExecutionListener... listeners)
Add all of the suppliedlisteners
to the configuration.- Parameters:
listeners
- additional test execution listeners to register; nevernull
or containingnull
- Returns:
- this builder for method chaining
-
build
public LauncherConfig build()
Build theLauncherConfig
that has been configured via this builder.
-
-