Package org.awaitility.core
Class EvaluationCleanup
java.lang.Object
org.awaitility.core.EvaluationCleanup
Handles how threads and thread-pools are cleanup after each conditional evaluation round.
I.e. each call to
until.- Since:
- 3.1.0
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final Consumer<ExecutorService>private final Consumer<ExecutorService> -
Constructor Summary
ConstructorsConstructorDescriptionEvaluationCleanup(Consumer<ExecutorService> normalShutdownBehavior, Consumer<ExecutorService> unexpectedShutdownBehavior) -
Method Summary
Modifier and TypeMethodDescription(package private) voidexecuteNormalCleanupBehavior(ExecutorService executorService) (package private) voidexecuteUnexpectedCleanupBehavior(ExecutorService executorService)
-
Field Details
-
normalShutdownBehavior
-
unexpectedShutdownBehavior
-
-
Constructor Details
-
EvaluationCleanup
EvaluationCleanup(Consumer<ExecutorService> normalShutdownBehavior, Consumer<ExecutorService> unexpectedShutdownBehavior) - Parameters:
normalShutdownBehavior- The cleanup behavior that is executed when anuntilmethod call succeeds, fails or times out.unexpectedShutdownBehavior- The cleanup behavior that is executed for unexpected failures. Currently this means when exceptions are thrown from non-test threads ("uncaught exceptions")
-
-
Method Details
-
executeNormalCleanupBehavior
-
executeUnexpectedCleanupBehavior
-