Class DefaultMethodOrdererContext
- java.lang.Object
-
- org.junit.jupiter.engine.discovery.DefaultMethodOrdererContext
-
- All Implemented Interfaces:
MethodOrdererContext
class DefaultMethodOrdererContext extends java.lang.Object implements MethodOrdererContext
Default implementation ofMethodOrdererContext.- Since:
- 5.4
-
-
Field Summary
Fields Modifier and Type Field Description private JupiterConfigurationconfigurationprivate java.util.List<? extends MethodDescriptor>methodDescriptorsprivate java.lang.Class<?>testClass
-
Constructor Summary
Constructors Constructor Description DefaultMethodOrdererContext(java.util.List<? extends MethodDescriptor> methodDescriptors, java.lang.Class<?> testClass, JupiterConfiguration configuration)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.util.Optional<java.lang.String>getConfigurationParameter(java.lang.String key)Get the configuration parameter stored under the specifiedkey.java.util.List<? extends MethodDescriptor>getMethodDescriptors()Get the list of method descriptors to order.java.lang.Class<?>getTestClass()Get the test class for this context.java.lang.StringtoString()
-
-
-
Field Detail
-
testClass
private final java.lang.Class<?> testClass
-
methodDescriptors
private final java.util.List<? extends MethodDescriptor> methodDescriptors
-
configuration
private final JupiterConfiguration configuration
-
-
Constructor Detail
-
DefaultMethodOrdererContext
DefaultMethodOrdererContext(java.util.List<? extends MethodDescriptor> methodDescriptors, java.lang.Class<?> testClass, JupiterConfiguration configuration)
-
-
Method Detail
-
getTestClass
public final java.lang.Class<?> getTestClass()
Description copied from interface:MethodOrdererContextGet the test class for this context.- Specified by:
getTestClassin interfaceMethodOrdererContext- Returns:
- the test class; never
null
-
getMethodDescriptors
public java.util.List<? extends MethodDescriptor> getMethodDescriptors()
Description copied from interface:MethodOrdererContextGet the list of method descriptors to order.- Specified by:
getMethodDescriptorsin interfaceMethodOrdererContext- Returns:
- the list of method descriptors; never
null
-
getConfigurationParameter
public java.util.Optional<java.lang.String> getConfigurationParameter(java.lang.String key)
Description copied from interface:MethodOrdererContextGet the configuration parameter stored under the specifiedkey.If no such key is present in the
ConfigurationParametersfor the JUnit Platform, an attempt will be made to look up the value as a JVM system property. If no such system property exists, an attempt will be made to look up the value in the JUnit Platform properties file.- Specified by:
getConfigurationParameterin interfaceMethodOrdererContext- Parameters:
key- the key to look up; nevernullor blank- Returns:
- an
Optionalcontaining the value; nevernullbut potentially empty - See Also:
System.getProperty(String),ConfigurationParameters
-
toString
public java.lang.String toString()
- Overrides:
toStringin classjava.lang.Object
-
-