Package org.testng.internal
Class TestNGMethodFinder
- java.lang.Object
-
- org.testng.internal.TestNGMethodFinder
-
- All Implemented Interfaces:
ITestMethodFinder
public class TestNGMethodFinder extends Object implements ITestMethodFinder
The default strategy for finding test methods: look up annotations @Test in front of methods.
-
-
Constructor Summary
Constructors Constructor Description TestNGMethodFinder(RunInfo runInfo, IAnnotationFinder annotationFinder)
TestNGMethodFinder(RunInfo runInfo, IAnnotationFinder annotationFinder, Comparator<ITestNGMethod> comparator)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ITestNGMethod[]
getAfterClassMethods(Class cls)
ITestNGMethod[]
getAfterGroupsConfigurationMethods(Class clazz)
ITestNGMethod[]
getAfterSuiteMethods(Class cls)
ITestNGMethod[]
getAfterTestConfigurationMethods(Class clazz)
ITestNGMethod[]
getAfterTestMethods(Class cls)
ITestNGMethod[]
getBeforeClassMethods(Class cls)
ITestNGMethod[]
getBeforeGroupsConfigurationMethods(Class clazz)
ITestNGMethod[]
getBeforeSuiteMethods(Class cls)
ITestNGMethod[]
getBeforeTestConfigurationMethods(Class clazz)
ITestNGMethod[]
getBeforeTestMethods(Class cls)
ITestNGMethod[]
getTestMethods(Class<?> clazz, XmlTest xmlTest)
-
-
-
Constructor Detail
-
TestNGMethodFinder
public TestNGMethodFinder(RunInfo runInfo, IAnnotationFinder annotationFinder)
-
TestNGMethodFinder
public TestNGMethodFinder(RunInfo runInfo, IAnnotationFinder annotationFinder, Comparator<ITestNGMethod> comparator)
-
-
Method Detail
-
getTestMethods
public ITestNGMethod[] getTestMethods(Class<?> clazz, XmlTest xmlTest)
- Specified by:
getTestMethods
in interfaceITestMethodFinder
- Returns:
- All the applicable test methods.
-
getBeforeClassMethods
public ITestNGMethod[] getBeforeClassMethods(Class cls)
- Specified by:
getBeforeClassMethods
in interfaceITestMethodFinder
- Returns:
- All the methods that should be invoked after the test class has been created and before any of its test methods is invoked.
-
getAfterClassMethods
public ITestNGMethod[] getAfterClassMethods(Class cls)
- Specified by:
getAfterClassMethods
in interfaceITestMethodFinder
- Returns:
- All the methods that should be invoked after the test class has been created and after all its test methods have completed.
-
getBeforeTestMethods
public ITestNGMethod[] getBeforeTestMethods(Class cls)
- Specified by:
getBeforeTestMethods
in interfaceITestMethodFinder
- Returns:
- All the methods that should be invoked before a test method is invoked.
-
getAfterTestMethods
public ITestNGMethod[] getAfterTestMethods(Class cls)
- Specified by:
getAfterTestMethods
in interfaceITestMethodFinder
- Returns:
- All the methods that should be invoked after a test method completes.
-
getBeforeSuiteMethods
public ITestNGMethod[] getBeforeSuiteMethods(Class cls)
- Specified by:
getBeforeSuiteMethods
in interfaceITestMethodFinder
- Returns:
- All the methods that should be invoked before the suite starts running.
-
getAfterSuiteMethods
public ITestNGMethod[] getAfterSuiteMethods(Class cls)
- Specified by:
getAfterSuiteMethods
in interfaceITestMethodFinder
- Returns:
- All the methods that should be invoked after the suite has run all its tests.
-
getBeforeTestConfigurationMethods
public ITestNGMethod[] getBeforeTestConfigurationMethods(Class clazz)
- Specified by:
getBeforeTestConfigurationMethods
in interfaceITestMethodFinder
-
getAfterTestConfigurationMethods
public ITestNGMethod[] getAfterTestConfigurationMethods(Class clazz)
- Specified by:
getAfterTestConfigurationMethods
in interfaceITestMethodFinder
-
getBeforeGroupsConfigurationMethods
public ITestNGMethod[] getBeforeGroupsConfigurationMethods(Class clazz)
- Specified by:
getBeforeGroupsConfigurationMethods
in interfaceITestMethodFinder
-
getAfterGroupsConfigurationMethods
public ITestNGMethod[] getAfterGroupsConfigurationMethods(Class clazz)
- Specified by:
getAfterGroupsConfigurationMethods
in interfaceITestMethodFinder
-
-