Class FluentTestNgSpringTest

    • Constructor Detail

      • FluentTestNgSpringTest

        public FluentTestNgSpringTest()
    • Method Detail

      • afterTest

        @AfterTest(alwaysRun=true)
        public void afterTest​(org.testng.ITestContext context)
        After test.
        Parameters:
        context - test context
      • beforeMethod

        @BeforeMethod(alwaysRun=true)
        public void beforeMethod​(Method method,
                                 org.testng.ITestContext context)
        Before test.
        Parameters:
        method - test method
        context - test context
      • afterMethod

        @AfterMethod(alwaysRun=true)
        public void afterMethod​(org.testng.ITestResult result)
        After test method.
        Parameters:
        result - test result
      • afterClass

        @AfterClass(alwaysRun=true)
        public void afterClass()
        After test class.
      • getClassAnnotation

        public <T extends Annotation> T getClassAnnotation​(Class<T> annotation)
        Description copied from interface: TestRunnerAdapter
        Allows to access Class level annotation of currently running test
        Specified by:
        getClassAnnotation in interface TestRunnerAdapter
        Type Parameters:
        T - the class annotation
        Parameters:
        annotation - interface you want to access
        Returns:
        Annotation instance
      • getMethodAnnotation

        public <T extends Annotation> T getMethodAnnotation​(Class<T> annotation)
        Description copied from interface: TestRunnerAdapter
        Allows to access method level annotation of currently running test
        Specified by:
        getMethodAnnotation in interface TestRunnerAdapter
        Type Parameters:
        T - the method annotation
        Parameters:
        annotation - interface you want to access
        Returns:
        Annotation instance
      • starting

        protected void starting​(Class<?> testClass,
                                String testName)
        Invoked when a test method is starting.
        Parameters:
        testClass - Test class
        testName - Test name
      • finished

        protected void finished​(Class<?> testClass,
                                String testName)
        Invoked when a test method has finished (whatever the success of failing status)
        Parameters:
        testClass - Test class
        testName - Test name
      • failed

        protected void failed​(Throwable e,
                              Class<?> testClass,
                              String testName)
        Invoked when a test method has failed (before finished)
        Parameters:
        e - Throwable thrown by the failing test.
        testClass - Test class
        testName - Test name