Package org.testng.internal
Class TestNGMethodFinder
java.lang.Object
org.testng.internal.TestNGMethodFinder
- All Implemented Interfaces:
ITestMethodFinder
The default strategy for finding test methods: look up annotations @Test in front of methods.
-
Constructor Summary
ConstructorsConstructorDescriptionTestNGMethodFinder
(RunInfo runInfo, IAnnotationFinder annotationFinder) TestNGMethodFinder
(RunInfo runInfo, IAnnotationFinder annotationFinder, Comparator<ITestNGMethod> comparator) -
Method Summary
Modifier and TypeMethodDescriptiongetAfterClassMethods
(Class<?> cls) getAfterGroupsConfigurationMethods
(Class<?> clazz) getAfterSuiteMethods
(Class<?> cls) getAfterTestConfigurationMethods
(Class<?> clazz) getAfterTestMethods
(Class<?> cls) getBeforeClassMethods
(Class<?> cls) getBeforeGroupsConfigurationMethods
(Class<?> clazz) getBeforeSuiteMethods
(Class<?> cls) getBeforeTestConfigurationMethods
(Class<?> clazz) getBeforeTestMethods
(Class<?> cls) getTestMethods
(Class<?> clazz, XmlTest xmlTest)
-
Constructor Details
-
TestNGMethodFinder
-
TestNGMethodFinder
public TestNGMethodFinder(RunInfo runInfo, IAnnotationFinder annotationFinder, Comparator<ITestNGMethod> comparator)
-
-
Method Details
-
getTestMethods
- Specified by:
getTestMethods
in interfaceITestMethodFinder
- Parameters:
clazz
- The test classxmlTest
- The test node of xml- Returns:
- All the applicable test methods.
-
getBeforeClassMethods
- Specified by:
getBeforeClassMethods
in interfaceITestMethodFinder
- Parameters:
cls
- The test class- 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
- Specified by:
getAfterClassMethods
in interfaceITestMethodFinder
- Parameters:
cls
- The test class- Returns:
- All the methods that should be invoked after the test class has been created and after all its test methods have completed.
-
getBeforeTestMethods
- Specified by:
getBeforeTestMethods
in interfaceITestMethodFinder
- Parameters:
cls
- The test class- Returns:
- All the methods that should be invoked before a test method is invoked.
-
getAfterTestMethods
- Specified by:
getAfterTestMethods
in interfaceITestMethodFinder
- Parameters:
cls
- The test class- Returns:
- All the methods that should be invoked after a test method completes.
-
getBeforeSuiteMethods
- Specified by:
getBeforeSuiteMethods
in interfaceITestMethodFinder
- Parameters:
cls
- The test class- Returns:
- All the methods that should be invoked before the suite starts running.
-
getAfterSuiteMethods
- Specified by:
getAfterSuiteMethods
in interfaceITestMethodFinder
- Parameters:
cls
- The test class- Returns:
- All the methods that should be invoked after the suite has run all its tests.
-
getBeforeTestConfigurationMethods
- Specified by:
getBeforeTestConfigurationMethods
in interfaceITestMethodFinder
-
getAfterTestConfigurationMethods
- Specified by:
getAfterTestConfigurationMethods
in interfaceITestMethodFinder
-
getBeforeGroupsConfigurationMethods
- Specified by:
getBeforeGroupsConfigurationMethods
in interfaceITestMethodFinder
-
getAfterGroupsConfigurationMethods
- Specified by:
getAfterGroupsConfigurationMethods
in interfaceITestMethodFinder
-