@Target([AnnotationTarget.FUNCTION, AnnotationTarget.PROPERTY_GETTER, AnnotationTarget.PROPERTY_SETTER, AnnotationTarget.ANNOTATION_CLASS]) class Timed
Test-specific annotation to indicate that a test method has to finish execution in a specified time period.
If the text execution takes longer than the specified time period, then the test is considered to have failed.
Note that the time period includes execution of the test method itself, any Repeat of the test, and any set up or tear down of the test fixture.
As of Spring Framework 4.0, this annotation may be used as a meta-annotation to create custom composed annotations.
Author
Rod Johnson
Author
Sam Brannen
Since
2.0
See Also
org.springframework.test.annotation.Repeatorg.springframework.test.context.junit4.SpringJUnit4ClassRunnerorg.springframework.test.context.junit4.rules.SpringMethodRuleorg.springframework.test.context.junit4.statements.SpringFailOnTimeout
Timed(millis: Long)
Test-specific annotation to indicate that a test method has to finish execution in a specified time period. If the text execution takes longer than the specified time period, then the test is considered to have failed. Note that the time period includes execution of the test method itself, any Repeat of the test, and any set up or tear down of the test fixture. As of Spring Framework 4.0, this annotation may be used as a meta-annotation to create custom composed annotations. |
val millis: Long
The maximum amount of time (in milliseconds) that a test execution can take without being marked as failed due to taking too long. |