public class OpenShiftRecorderHandler extends Object implements org.junit.jupiter.api.extension.TestWatcher, org.junit.jupiter.api.extension.TestExecutionExceptionHandler, org.junit.jupiter.api.extension.BeforeAllCallback, org.junit.jupiter.api.extension.BeforeEachCallback, org.junit.jupiter.api.extension.LifecycleMethodExecutionExceptionHandler
OpenShiftRecorderService.
Based on the JUnit test life cycle event that is being handled, an instance of this class will either call
OpenShiftRecorderService.initFilters(ExtensionContext) - beforeAllCallback: used to get information on what
resources are on a cluster before a test class is processed
OpenShiftRecorderService.updateFilters(ExtensionContext) - beforeEachCallback: used to get information on
what resources are on a cluster before a test case is processed
OpenShiftRecorderService.recordState(ExtensionContext) - on various events: used to record state of
selected resources (by name) or make an estimation based on information collected when previous events like the two
described above took place
OpenShift state is recorded in the following cases:
TestExecutionExceptionHandler.handleTestExecutionException(org.junit.jupiter.api.extension.ExtensionContext, java.lang.Throwable)LifecycleMethodExecutionExceptionHandler.handleBeforeAllMethodExecutionException(ExtensionContext, Throwable)
and LifecycleMethodExecutionExceptionHandler.handleBeforeEachMethodExecutionException(ExtensionContext, Throwable)
in case xtf.record.before is setTestWatcher.testSuccessful(ExtensionContext) in case xtf.record.before is set| Constructor and Description |
|---|
OpenShiftRecorderHandler() |
| Modifier and Type | Method and Description |
|---|---|
void |
beforeAll(org.junit.jupiter.api.extension.ExtensionContext context) |
void |
beforeEach(org.junit.jupiter.api.extension.ExtensionContext context) |
void |
handleBeforeAllMethodExecutionException(org.junit.jupiter.api.extension.ExtensionContext context,
Throwable throwable) |
void |
handleBeforeEachMethodExecutionException(org.junit.jupiter.api.extension.ExtensionContext context,
Throwable throwable) |
void |
handleTestExecutionException(org.junit.jupiter.api.extension.ExtensionContext context,
Throwable throwable) |
void |
testSuccessful(org.junit.jupiter.api.extension.ExtensionContext context) |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitpublic void beforeAll(org.junit.jupiter.api.extension.ExtensionContext context)
beforeAll in interface org.junit.jupiter.api.extension.BeforeAllCallbackpublic void beforeEach(org.junit.jupiter.api.extension.ExtensionContext context)
beforeEach in interface org.junit.jupiter.api.extension.BeforeEachCallbackpublic void handleTestExecutionException(org.junit.jupiter.api.extension.ExtensionContext context,
Throwable throwable)
throws Throwable
handleTestExecutionException in interface org.junit.jupiter.api.extension.TestExecutionExceptionHandlerThrowablepublic void handleBeforeAllMethodExecutionException(org.junit.jupiter.api.extension.ExtensionContext context,
Throwable throwable)
throws Throwable
handleBeforeAllMethodExecutionException in interface org.junit.jupiter.api.extension.LifecycleMethodExecutionExceptionHandlerThrowablepublic void handleBeforeEachMethodExecutionException(org.junit.jupiter.api.extension.ExtensionContext context,
Throwable throwable)
throws Throwable
handleBeforeEachMethodExecutionException in interface org.junit.jupiter.api.extension.LifecycleMethodExecutionExceptionHandlerThrowablepublic void testSuccessful(org.junit.jupiter.api.extension.ExtensionContext context)
testSuccessful in interface org.junit.jupiter.api.extension.TestWatcherCopyright © 2025. All rights reserved.