* annotation on the supplied {@link FrameworkMethod test method}.
* @return the timeout, or {@code 0} if none was specified.
*/
protected long getJUnitTimeout(FrameworkMethod frameworkMethod) {
Test testAnnotation = frameworkMethod.getAnnotation(Test.class);
return (testAnnotation != null && testAnnotation.timeout() > 0 ? testAnnotation.timeout() : 0);
}
/**
* Retrieves the configured Spring-specific {@code timeout} from the
* {@link Timed @Timed} annotation on the supplied