Java 类org.springframework.test.context.web.WebAppConfiguration 实例源码

项目:https-github.com-g0t4-jenkins2-course-spring-boot    文件:SpringApplicationContextLoader.java   
private void assertValidAnnotations(Class<?> testClass) {
    boolean hasWebAppConfiguration = AnnotationUtils.findAnnotation(testClass,
            WebAppConfiguration.class) != null;
    boolean hasWebIntegrationTest = AnnotationUtils.findAnnotation(testClass,
            WebIntegrationTest.class) != null;
    if (hasWebAppConfiguration && hasWebIntegrationTest) {
        throw new IllegalStateException("@WebIntegrationTest and "
                + "@WebAppConfiguration cannot be used together");
    }
}
项目:spring-boot-concourse    文件:SpringApplicationContextLoader.java   
private void assertValidAnnotations(Class<?> testClass) {
    boolean hasWebAppConfiguration = AnnotationUtils.findAnnotation(testClass,
            WebAppConfiguration.class) != null;
    boolean hasWebIntegrationTest = AnnotationUtils.findAnnotation(testClass,
            WebIntegrationTest.class) != null;
    if (hasWebAppConfiguration && hasWebIntegrationTest) {
        throw new IllegalStateException("@WebIntegrationTest and "
                + "@WebAppConfiguration cannot be used together");
    }
}
项目:contestparser    文件:SpringApplicationContextLoader.java   
private void assertValidAnnotations(Class<?> testClass) {
    boolean hasWebAppConfiguration = AnnotationUtils.findAnnotation(testClass,
            WebAppConfiguration.class) != null;
    boolean hasWebIntegrationTest = AnnotationUtils.findAnnotation(testClass,
            WebIntegrationTest.class) != null;
    if (hasWebAppConfiguration && hasWebIntegrationTest) {
        throw new IllegalStateException("@WebIntegrationTest and "
                + "@WebAppConfiguration cannot be used together");
    }
}