Package org.citrusframework.util
Class TestUtils
java.lang.Object
org.citrusframework.util.TestUtils
Utility class for test cases providing several utility
methods regarding Citrus test cases.
-
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionstatic StringgetTestName(org.citrusframework.context.TestContext context) static booleanstatic StringnormalizeLineEndings(String text) Normalize the text by trimming whitespace and replacing line endings by a linux representation.static voidwaitForCompletion(ScheduledExecutorService scheduledExecutor, org.citrusframework.Completable container, org.citrusframework.context.TestContext context, long timeout) Uses given scheduler to wait for container to finish properly.static voidwaitForCompletion(org.citrusframework.Completable container, org.citrusframework.context.TestContext context) Wait for container completion with default timeout.static voidwaitForCompletion(org.citrusframework.Completable container, org.citrusframework.context.TestContext context, long timeout) Wait for container completion using default thread executor.
-
Field Details
-
HTTPS_CITRUSFRAMEWORK_ORG
- See Also:
-
WAIT_THREAD_PREFIX
Used to identify waiting task threads pool- See Also:
-
-
Method Details
-
waitForCompletion
public static void waitForCompletion(org.citrusframework.Completable container, org.citrusframework.context.TestContext context) Wait for container completion with default timeout. -
waitForCompletion
public static void waitForCompletion(org.citrusframework.Completable container, org.citrusframework.context.TestContext context, long timeout) Wait for container completion using default thread executor. -
waitForCompletion
public static void waitForCompletion(ScheduledExecutorService scheduledExecutor, org.citrusframework.Completable container, org.citrusframework.context.TestContext context, long timeout) Uses given scheduler to wait for container to finish properly. Method polls for done state on container for given amount of time. -
getTestName
-
normalizeLineEndings
Normalize the text by trimming whitespace and replacing line endings by a linux representation. -
isNetworkReachable
public static boolean isNetworkReachable()
-