-
@Deprecated @Target({ANNOTATION_TYPE,METHOD}) @Retention(RUNTIME) @ExtendWith(ExpectedExceptionExtension.class) @ExtendWith(TimeoutExtension.class) @Test public @interface TestDeprecated.This annotation is an intermediate step on a full migration from JUnit 4's@Testto Jupiter's. To emphasize its character as a temporary solution and to reduce risk of accidental use, it's marked as deprecated. Deprecated since v0.4; not intended to be removed.@Testis used to signal to JUnit Jupiter that the annotated method is a test method - it is a drop-in replacement for JUnit 4's@Test.Like JUnit 4's annotation it offers the possibility to
expect exceptionsand totime outlong running tests.Also check Jupiter's
@Testfor more information regarding JUnit Jupiter integration and Pioneer's documentation on this@Testfor more details and examples.- Since:
- 0.1
-
-
Optional Element Summary
Optional Elements Modifier and Type Optional Element Description java.lang.Class<? extends java.lang.Throwable>expectedDeprecated.Optionally specifyexpected, a Throwable, to cause a test method to succeed if and only if an exception of the specified class is thrown by the method.longtimeoutDeprecated.Optionally specifytimeoutin milliseconds to cause a test method to fail if it takes longer than that number of milliseconds.
-
-
-
-
timeout
long timeout
Deprecated.Optionally specifytimeoutin milliseconds to cause a test method to fail if it takes longer than that number of milliseconds.If the timeout is exceeded, the test will be abandoned (i.e. the test execution moves on to the next test) and the thread running it is interrupted.
In accordance with JUnit 4, the default value is
0, which means that while configuring 0 milliseconds is possible, it is indistinguishable from the default value and thus ignored. Negative values are rejected with an exception.- Default:
- 0L
-
-