Interface TestExecutionListener

All Known Implementing Classes:
AbstractMicronautExtension, MicronautJunit5Extension, MicronautSpockExtension

public interface TestExecutionListener
Test execution listener.
Since:
1.2
Author:
bidorffOL
  • Method Details

    • beforeTestClass

      default void beforeTestClass(TestContext testContext) throws Exception
      Executed before all of the tests of a class are executed.
      Parameters:
      testContext - the test context
      Throws:
      Exception - allows any exception to propagate
    • beforeSetupTest

      default void beforeSetupTest(TestContext testContext) throws Exception
      Executed before the setup method of a test method.
      Parameters:
      testContext - the test context
      Throws:
      Exception - allows any exception to propagate
    • afterSetupTest

      default void afterSetupTest(TestContext testContext) throws Exception
      Executed after the setup method of a test method.
      Parameters:
      testContext - the test context
      Throws:
      Exception - allows any exception to propagate
    • beforeCleanupTest

      default void beforeCleanupTest(TestContext testContext) throws Exception
      Executed before the setup method of a test method.
      Parameters:
      testContext - the test context
      Throws:
      Exception - allows any exception to propagate
    • afterCleanupTest

      default void afterCleanupTest(TestContext testContext) throws Exception
      Executed after the setup method of a test method.
      Parameters:
      testContext - the test context
      Throws:
      Exception - allows any exception to propagate
    • beforeTestMethod

      default void beforeTestMethod(TestContext testContext) throws Exception
      Executed before a test method is executed (a test method may contain multiple iterations).
      Parameters:
      testContext - the test context
      Throws:
      Exception - allows any exception to propagate
    • beforeTestExecution

      default void beforeTestExecution(TestContext testContext) throws Exception
      Executed before a single test iteration is executed.
      Parameters:
      testContext - the test context
      Throws:
      Exception - allows any exception to propagate
    • afterTestExecution

      default void afterTestExecution(TestContext testContext) throws Exception
      Executed after a single test iteration has been executed .
      Parameters:
      testContext - the test context
      Throws:
      Exception - allows any exception to propagate
    • afterTestMethod

      default void afterTestMethod(TestContext testContext) throws Exception
      Executed after a test method has been executed (a test method may contain multiple iterations).
      Parameters:
      testContext - the test context
      Throws:
      Exception - allows any exception to propagate
    • afterTestClass

      default void afterTestClass(TestContext testContext) throws Exception
      Executed after all of the tests of a class have bean executed.
      Parameters:
      testContext - the test context
      Throws:
      Exception - allows any exception to propagate