Java Code Examples for org.springframework.test.annotation.TestAnnotationUtils

The following examples show how to use org.springframework.test.annotation.TestAnnotationUtils. These examples are extracted from open source projects. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source Project: spring-analysis-note   Source File: SpringJUnit4ClassRunner.java    License: MIT License 2 votes vote down vote up
/**
 * Retrieve the configured Spring-specific {@code timeout} from the
 * {@link org.springframework.test.annotation.Timed @Timed} annotation
 * on the supplied {@linkplain FrameworkMethod test method}.
 * @return the timeout, or {@code 0} if none was specified
 * @see TestAnnotationUtils#getTimeout(Method)
 */
protected long getSpringTimeout(FrameworkMethod frameworkMethod) {
	return TestAnnotationUtils.getTimeout(frameworkMethod.getMethod());
}
 
Example 2
Source Project: spring-analysis-note   Source File: SpringRepeat.java    License: MIT License 2 votes vote down vote up
/**
 * Construct a new {@code SpringRepeat} statement for the supplied
 * {@code testMethod}, retrieving the configured repeat count from the
 * {@code @Repeat} annotation on the supplied method.
 * @param next the next {@code Statement} in the execution chain
 * @param testMethod the current test method
 * @see TestAnnotationUtils#getRepeatCount(Method)
 */
public SpringRepeat(Statement next, Method testMethod) {
	this(next, testMethod, TestAnnotationUtils.getRepeatCount(testMethod));
}
 
Example 3
Source Project: spring-analysis-note   Source File: SpringFailOnTimeout.java    License: MIT License 2 votes vote down vote up
/**
 * Construct a new {@code SpringFailOnTimeout} statement for the supplied
 * {@code testMethod}, retrieving the configured timeout from the
 * {@code @Timed} annotation on the supplied method.
 * @param next the next {@code Statement} in the execution chain
 * @param testMethod the current test method
 * @see TestAnnotationUtils#getTimeout(Method)
 */
public SpringFailOnTimeout(Statement next, Method testMethod) {
	this(next, TestAnnotationUtils.getTimeout(testMethod));
}
 
Example 4
Source Project: java-technology-stack   Source File: SpringJUnit4ClassRunner.java    License: MIT License 2 votes vote down vote up
/**
 * Retrieve the configured Spring-specific {@code timeout} from the
 * {@link org.springframework.test.annotation.Timed @Timed} annotation
 * on the supplied {@linkplain FrameworkMethod test method}.
 * @return the timeout, or {@code 0} if none was specified
 * @see TestAnnotationUtils#getTimeout(Method)
 */
protected long getSpringTimeout(FrameworkMethod frameworkMethod) {
	return TestAnnotationUtils.getTimeout(frameworkMethod.getMethod());
}
 
Example 5
Source Project: java-technology-stack   Source File: SpringRepeat.java    License: MIT License 2 votes vote down vote up
/**
 * Construct a new {@code SpringRepeat} statement for the supplied
 * {@code testMethod}, retrieving the configured repeat count from the
 * {@code @Repeat} annotation on the supplied method.
 * @param next the next {@code Statement} in the execution chain
 * @param testMethod the current test method
 * @see TestAnnotationUtils#getRepeatCount(Method)
 */
public SpringRepeat(Statement next, Method testMethod) {
	this(next, testMethod, TestAnnotationUtils.getRepeatCount(testMethod));
}
 
Example 6
Source Project: java-technology-stack   Source File: SpringFailOnTimeout.java    License: MIT License 2 votes vote down vote up
/**
 * Construct a new {@code SpringFailOnTimeout} statement for the supplied
 * {@code testMethod}, retrieving the configured timeout from the
 * {@code @Timed} annotation on the supplied method.
 * @param next the next {@code Statement} in the execution chain
 * @param testMethod the current test method
 * @see TestAnnotationUtils#getTimeout(Method)
 */
public SpringFailOnTimeout(Statement next, Method testMethod) {
	this(next, TestAnnotationUtils.getTimeout(testMethod));
}
 
Example 7
/**
 * Retrieve the configured Spring-specific {@code timeout} from the
 * {@link org.springframework.test.annotation.Timed @Timed} annotation
 * on the supplied {@linkplain FrameworkMethod test method}.
 * @return the timeout, or {@code 0} if none was specified
 * @see TestAnnotationUtils#getTimeout(Method)
 */
protected long getSpringTimeout(FrameworkMethod frameworkMethod) {
	return TestAnnotationUtils.getTimeout(frameworkMethod.getMethod());
}
 
Example 8
Source Project: spring4-understanding   Source File: SpringRepeat.java    License: Apache License 2.0 2 votes vote down vote up
/**
 * Construct a new {@code SpringRepeat} statement for the supplied
 * {@code testMethod}, retrieving the configured repeat count from the
 * {@code @Repeat} annotation on the supplied method.
 * @param next the next {@code Statement} in the execution chain
 * @param testMethod the current test method
 * @see TestAnnotationUtils#getRepeatCount(Method)
 */
public SpringRepeat(Statement next, Method testMethod) {
	this(next, testMethod, TestAnnotationUtils.getRepeatCount(testMethod));
}
 
Example 9
Source Project: spring4-understanding   Source File: SpringFailOnTimeout.java    License: Apache License 2.0 2 votes vote down vote up
/**
 * Construct a new {@code SpringFailOnTimeout} statement for the supplied
 * {@code testMethod}, retrieving the configured timeout from the
 * {@code @Timed} annotation on the supplied method.
 * @param next the next {@code Statement} in the execution chain
 * @param testMethod the current test method
 * @see TestAnnotationUtils#getTimeout(Method)
 */
public SpringFailOnTimeout(Statement next, Method testMethod) {
	this(next, TestAnnotationUtils.getTimeout(testMethod));
}