Polishing
This commit is contained in:
@@ -31,8 +31,8 @@ import org.apache.commons.logging.LogFactory;
|
||||
|
||||
import org.springframework.beans.BeanInstantiationException;
|
||||
import org.springframework.beans.BeanUtils;
|
||||
import org.springframework.core.annotation.AnnotatedElementUtils;
|
||||
import org.springframework.core.annotation.AnnotationAwareOrderComparator;
|
||||
import org.springframework.core.annotation.AnnotationUtils;
|
||||
import org.springframework.core.io.support.SpringFactoriesLoader;
|
||||
import org.springframework.test.context.BootstrapContext;
|
||||
import org.springframework.test.context.CacheAwareContextLoaderDelegate;
|
||||
@@ -278,7 +278,7 @@ public abstract class AbstractTestContextBootstrapper implements TestContextBoot
|
||||
return buildDefaultMergedContextConfiguration(testClass, cacheAwareContextLoaderDelegate);
|
||||
}
|
||||
|
||||
if (AnnotatedElementUtils.findMergedAnnotation(testClass, ContextHierarchy.class) != null) {
|
||||
if (AnnotationUtils.findAnnotation(testClass, ContextHierarchy.class) != null) {
|
||||
Map<String, List<ContextConfigurationAttributes>> hierarchyMap = ContextLoaderUtils.buildContextHierarchyMap(testClass);
|
||||
MergedContextConfiguration parentConfig = null;
|
||||
MergedContextConfiguration mergedConfig = null;
|
||||
|
||||
@@ -81,13 +81,12 @@ abstract class ContextLoaderUtils {
|
||||
* (must not be {@code null})
|
||||
* @return the list of lists of configuration attributes for the specified class;
|
||||
* never {@code null}
|
||||
* @throws IllegalArgumentException if the supplied class is {@code null}; if
|
||||
* @throws IllegalArgumentException if the supplied class is {@code null}; or if
|
||||
* neither {@code @ContextConfiguration} nor {@code @ContextHierarchy} is
|
||||
* <em>present</em> on the supplied class; or if a test class or composed annotation
|
||||
* <em>present</em> on the supplied class
|
||||
* @throws IllegalStateException if a test class or composed annotation
|
||||
* in the class hierarchy declares both {@code @ContextConfiguration} and
|
||||
* {@code @ContextHierarchy} as top-level annotations.
|
||||
* @throws IllegalStateException if no class in the class hierarchy declares
|
||||
* {@code @ContextHierarchy}.
|
||||
* @since 3.2.2
|
||||
* @see #buildContextHierarchyMap(Class)
|
||||
* @see #resolveContextConfigurationAttributes(Class)
|
||||
|
||||
Reference in New Issue
Block a user