java.lang.Object
org.junit.platform.engine.ExecutionRequest
Provides a single
TestEngine access to the information necessary to
execute its tests.
A request contains an engine's root TestDescriptor, the
EngineExecutionListener to be notified of test execution events, the
ConfigurationParameters that the engine may use to influence test
execution, and an OutputDirectoryProvider for writing reports and
other output files.
- Since:
- 1.0
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionExecutionRequest(TestDescriptor rootTestDescriptor, EngineExecutionListener engineExecutionListener, ConfigurationParameters configurationParameters) Deprecated. -
Method Summary
Modifier and TypeMethodDescriptionstatic ExecutionRequestcreate(TestDescriptor rootTestDescriptor, EngineExecutionListener engineExecutionListener, ConfigurationParameters configurationParameters) Deprecated.static ExecutionRequestcreate(TestDescriptor rootTestDescriptor, EngineExecutionListener engineExecutionListener, ConfigurationParameters configurationParameters, OutputDirectoryProvider outputDirectoryProvider) Factory for creating an execution request.Returns theConfigurationParametersthat the engine may use to influence test execution.Returns theEngineExecutionListenerto be notified of test execution events.Returns theOutputDirectoryProviderfor this request for writing reports and other output files.Returns the rootTestDescriptorof the engine that processes this request.
-
Constructor Details
-
ExecutionRequest
@Deprecated @API(status=DEPRECATED, since="1.11") public ExecutionRequest(TestDescriptor rootTestDescriptor, EngineExecutionListener engineExecutionListener, ConfigurationParameters configurationParameters) Deprecated.
-
-
Method Details
-
create
@Deprecated @API(status=DEPRECATED, since="1.11") public static ExecutionRequest create(TestDescriptor rootTestDescriptor, EngineExecutionListener engineExecutionListener, ConfigurationParameters configurationParameters) Deprecated.Factory for creating an execution request.- Parameters:
rootTestDescriptor- the engine's rootTestDescriptorengineExecutionListener- theEngineExecutionListenerto be notified of test execution eventsconfigurationParameters-ConfigurationParametersthat the engine may use to influence test execution- Returns:
- a new
ExecutionRequest; nevernull - Since:
- 1.9
-
create
@API(status=INTERNAL, since="1.12") public static ExecutionRequest create(TestDescriptor rootTestDescriptor, EngineExecutionListener engineExecutionListener, ConfigurationParameters configurationParameters, OutputDirectoryProvider outputDirectoryProvider) Factory for creating an execution request.- Parameters:
rootTestDescriptor- the engine's rootTestDescriptor; nevernullengineExecutionListener- theEngineExecutionListenerto be notified of test execution events; nevernullconfigurationParameters-ConfigurationParametersthat the engine may use to influence test execution; nevernulloutputDirectoryProvider-OutputDirectoryProviderfor writing reports and other output files; nevernull- Returns:
- a new
ExecutionRequest; nevernull - Since:
- 1.12
-
getRootTestDescriptor
Returns the rootTestDescriptorof the engine that processes this request.Note: the root descriptor is the
TestDescriptorreturned byTestEngine.discover(EngineDiscoveryRequest, UniqueId).- Returns:
- the root
TestDescriptorof the engine that processes this request
-
getEngineExecutionListener
Returns theEngineExecutionListenerto be notified of test execution events.- Returns:
- the
EngineExecutionListenerto be notified of test execution events
-
getConfigurationParameters
Returns theConfigurationParametersthat the engine may use to influence test execution.- Returns:
- the
ConfigurationParametersthat the engine may use to influence test execution
-
getOutputDirectoryProvider
Returns theOutputDirectoryProviderfor this request for writing reports and other output files.- Returns:
- the
OutputDirectoryProviderfor this request for writing reports and other output files - Throws:
PreconditionViolationException- if the output directory provider is not available- Since:
- 1.12
-
create(TestDescriptor, EngineExecutionListener, ConfigurationParameters, OutputDirectoryProvider)