public class SimpleTestSelector extends Object implements TestSelector
TestDescription
will match if this selector's class-part is identical to the
TestDescriptions class name (same for the method name).Constructor and Description |
---|
SimpleTestSelector(String className,
String methodName) |
Modifier and Type | Method and Description |
---|---|
boolean |
containsClassPath(String classPath) |
String |
getExplanation() |
String |
getRawSelector() |
boolean |
isInclusive() |
boolean |
isMatchAnyClass() |
boolean |
isMatchAnyMethod() |
boolean |
matches(TestDescription description)
Whether this
TestSelector matches the given TestDescription . |
boolean |
matchesClassName(String thatClassName) |
public String getRawSelector()
getRawSelector
in interface TestSelector
public String getExplanation()
getExplanation
in interface TestSelector
public boolean isInclusive()
isInclusive
in interface TestSelector
public boolean isMatchAnyClass()
isMatchAnyClass
in interface TestSelector
public boolean isMatchAnyMethod()
isMatchAnyMethod
in interface TestSelector
public boolean matches(TestDescription description)
TestSelector
TestSelector
matches the given TestDescription
. A class or method
name being null in the TestDescription
means that it will match anything.matches
in interface TestSelector
description
- the TestDescription
to matchTestDescription
public boolean matchesClassName(String thatClassName)
matchesClassName
in interface TestSelector
public boolean containsClassPath(String classPath)
containsClassPath
in interface TestSelector