Package org.junit.runners.model
Class TestTimedOutException
- java.lang.Object
-
- java.lang.Throwable
-
- java.lang.Exception
-
- org.junit.runners.model.TestTimedOutException
-
- All Implemented Interfaces:
java.io.Serializable
public class TestTimedOutException extends java.lang.ExceptionException thrown when a test fails on timeout.- Since:
- 4.12
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description private static longserialVersionUIDprivate longtimeoutprivate java.util.concurrent.TimeUnittimeUnit
-
Constructor Summary
Constructors Constructor Description TestTimedOutException(long timeout, java.util.concurrent.TimeUnit timeUnit)Creates exception with a standard message "test timed out after [timeout] [timeUnit]"
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description longgetTimeout()Gets the time passed before the test was interruptedjava.util.concurrent.TimeUnitgetTimeUnit()Gets the time unit for the timeout value
-
-
-
Field Detail
-
serialVersionUID
private static final long serialVersionUID
- See Also:
- Constant Field Values
-
timeUnit
private final java.util.concurrent.TimeUnit timeUnit
-
timeout
private final long timeout
-
-
Constructor Detail
-
TestTimedOutException
public TestTimedOutException(long timeout, java.util.concurrent.TimeUnit timeUnit)Creates exception with a standard message "test timed out after [timeout] [timeUnit]"- Parameters:
timeout- the amount of time passed before the test was interruptedtimeUnit- the time unit for the timeout value
-
-