Top Description Methods
org.junit.platform.engine

public Interface EngineDiscoveryRequest

Annotations
@API
status:STABLE
since:1.0
Static Imports
org.apiguardian.api.API.Status.DEPRECATED, .API.Status.MAINTAINED, .API.Status.STABLE

EngineDiscoveryRequest provides a TestEngine access to the information necessary to discover tests and containers.

A request is comprised of selectors and filters. While the former select resources that engines can use to discover tests, the latter specify how such resources are to be filtered. All of the filters have to include a resource for it to end up in the test plan.

In addition, the supplied configuration parameters can be used to influence the discovery process.

Since
1.0
See Also
TestEngine, TestDescriptor, DiscoverySelector, DiscoveryFilter, ConfigurationParameters

Method Summary

Modifier and TypeMethod and Description
public ConfigurationParameters

Returns:

the configuration parameters; never null
getConfigurationParameters
()

Get the ConfigurationParameters for this request.

public default EngineDiscoveryListener

Returns:

the discovery listener; never null
getDiscoveryListener
()

Get the EngineDiscoveryListener for this request.

public <T extends DiscoveryFilter<?>> List<T>

Returns:

all filters of this request that are instances of filterType; never null but potentially empty
getFiltersByType
(Class<T>
the type of DiscoveryFilter to filter by; never null
filterType
)

Get the DiscoveryFilters for this request, filtered by a particular type.

public default OutputDirectoryCreator

Returns:

the output directory creator; never null
getOutputDirectoryCreator
()

Get the OutputDirectoryCreator for this request.

public default OutputDirectoryProvider

Returns:

the output directory provider; never null
getOutputDirectoryProvider
()
Deprecated for removal since 1.14. Please use getOutputDirectoryCreator() instead

Get the org.junit.platform.engine.reporting.OutputDirectoryProvider for this request.

public <T extends DiscoverySelector> List<T>

Returns:

all selectors of this request that are instances of selectorType; never null but potentially empty
getSelectorsByType
(Class<T>
the type of DiscoverySelector to filter by; never null
selectorType
)

Get the DiscoverySelectors for this request, filtered by a particular type.

Method Detail

getConfigurationParametersback to summary
public ConfigurationParameters getConfigurationParameters()

Get the ConfigurationParameters for this request.

Returns:ConfigurationParameters

the configuration parameters; never null

getDiscoveryListenerback to summary
public default EngineDiscoveryListener getDiscoveryListener()

Get the EngineDiscoveryListener for this request.

Returns:EngineDiscoveryListener

the discovery listener; never null

Annotations
@API
status:STABLE
since:1.10
Since
1.6
getFiltersByTypeback to summary
public <T extends DiscoveryFilter<?>> List<T> getFiltersByType(Class<T> filterType)

Get the DiscoveryFilters for this request, filtered by a particular type.

The returned filters are to be combined using AND semantics, i.e. all of them have to include a resource for it to end up in the test plan.

Parameters
filterType:Class<T>

the type of DiscoveryFilter to filter by; never null

Returns:List<T>

all filters of this request that are instances of filterType; never null but potentially empty

getOutputDirectoryCreatorback to summary
public default OutputDirectoryCreator getOutputDirectoryCreator()

Get the OutputDirectoryCreator for this request.

Returns:OutputDirectoryCreator

the output directory creator; never null

Annotations
@API
status:MAINTAINED
since:1.14
Since
1.14
getOutputDirectoryProviderback to summary
public default OutputDirectoryProvider getOutputDirectoryProvider()

Deprecated

for removal since 1.14.

Please use getOutputDirectoryCreator() instead

Get the org.junit.platform.engine.reporting.OutputDirectoryProvider for this request.

Returns:OutputDirectoryProvider

the output directory provider; never null

Annotations
@SuppressWarnings:removal
@Deprecated
since:1.14
forRemoval:true
@API
status:DEPRECATED
since:1.14
Since
1.12
getSelectorsByTypeback to summary
public <T extends DiscoverySelector> List<T> getSelectorsByType(Class<T> selectorType)

Get the DiscoverySelectors for this request, filtered by a particular type.

Parameters
selectorType:Class<T>

the type of DiscoverySelector to filter by; never null

Returns:List<T>

all selectors of this request that are instances of selectorType; never null but potentially empty