Class TestResourcesScopeListener
java.lang.Object
io.micronaut.test.extensions.junit5.TestResourcesScopeListener
- All Implemented Interfaces:
org.junit.platform.launcher.TestExecutionListener
public class TestResourcesScopeListener
extends Object
implements org.junit.platform.launcher.TestExecutionListener
A listener which is responsible for shutting down test resources for a
particular scope once the last test which uses this scope is finished.
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
executionFinished
(org.junit.platform.launcher.TestIdentifier id, org.junit.platform.engine.TestExecutionResult testExecutionResult) void
executionStarted
(org.junit.platform.launcher.TestIdentifier id) static Optional<TestResourcesScope>
findTestResourceScopeAnnotation
(Class<?> clazz) void
testPlanExecutionStarted
(org.junit.platform.launcher.TestPlan testPlan) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.junit.platform.launcher.TestExecutionListener
dynamicTestRegistered, executionSkipped, reportingEntryPublished, testPlanExecutionFinished
-
Constructor Details
-
TestResourcesScopeListener
public TestResourcesScopeListener()
-
-
Method Details
-
testPlanExecutionStarted
public void testPlanExecutionStarted(org.junit.platform.launcher.TestPlan testPlan) - Specified by:
testPlanExecutionStarted
in interfaceorg.junit.platform.launcher.TestExecutionListener
-
executionStarted
public void executionStarted(org.junit.platform.launcher.TestIdentifier id) - Specified by:
executionStarted
in interfaceorg.junit.platform.launcher.TestExecutionListener
-
executionFinished
public void executionFinished(org.junit.platform.launcher.TestIdentifier id, org.junit.platform.engine.TestExecutionResult testExecutionResult) - Specified by:
executionFinished
in interfaceorg.junit.platform.launcher.TestExecutionListener
-
findTestResourceScopeAnnotation
-