Class Configuration
java.lang.Object
com.github.sbt.junit.jupiter.internal.Configuration
-
Constructor Summary
ConstructorsConstructorDescriptionConfiguration(String testSuiteName, sbt.testing.Logger[] loggers, Options options) -
Method Summary
Modifier and TypeMethodDescriptionbuildErrorName(org.junit.platform.launcher.TestIdentifier identifier) buildInfoName(org.junit.platform.launcher.TestIdentifier identifier) Optional<org.junit.platform.launcher.TestExecutionListener>createRunListener(ClassLoader classLoader) Creates instances of test listeners using the specifiedclassLoader.decodeName(String name) extractClassName(org.junit.platform.launcher.TestIdentifier identifier) Extracts the class-name from the specified test identifier.extractClassNameOrDisplayName(org.junit.platform.launcher.TestIdentifier identifier) Extracts the class-name or alternatively the display name from the given identifier.extractMethodName(org.junit.platform.launcher.TestIdentifier identifier) Extracts the method-name from the specified test identifier.formatIdentifier(org.junit.platform.launcher.TestPlan testPlan, org.junit.platform.launcher.TestIdentifier identifier)
-
Constructor Details
-
Configuration
-
-
Method Details
-
getColorTheme
- Returns:
- The configured color theme.
-
getLogger
- Returns:
- The configured test logger.
-
getOptions
- Returns:
- The provided commandline options.
-
getTestSuiteName
- Returns:
- The name of the test suite which is currently executed.
- See Also:
-
TaskDef.fullyQualifiedName()
-
getTestListener
- Returns:
- The configured test listener.
-
createRunListener
public Optional<org.junit.platform.launcher.TestExecutionListener> createRunListener(ClassLoader classLoader) Creates instances of test listeners using the specifiedclassLoader.- Parameters:
classLoader- The class loader which should be used to load test listeners.- Returns:
- The list of test listener instances supplied via the command line.
-
decodeName
- Parameters:
name- The name which is to be decoded.- Returns:
- The decoded name, if
Options.isDecodeScalaNames()evaluates to true.
-
formatIdentifier
public String formatIdentifier(org.junit.platform.launcher.TestPlan testPlan, org.junit.platform.launcher.TestIdentifier identifier) - Parameters:
testPlan- The test plan of the specified identifier.identifier- The test identifier which is to be formatted.- Returns:
- The formatted display name for the specified identifier.
-
extractClassNameOrDisplayName
Extracts the class-name or alternatively the display name from the given identifier.- Parameters:
identifier- The identifier from which to extract the class-name or display name.- Returns:
- The class-name of the specified test identifier if a source is attached to the identifier, otherwise the display name is returned.
-
extractClassName
Extracts the class-name from the specified test identifier.- Parameters:
identifier- The identifier from which to extract the class-name.- Returns:
- The class-name of the specified test identifier.
-
extractMethodName
Extracts the method-name from the specified test identifier.- Parameters:
identifier- The identifier from which to extract the method-name.- Returns:
- The method-name of the specified test identifier.
-
buildInfoMessage
-
buildInfoName
-
buildErrorMessage
-
buildErrorName
-