diff --git a/spring-boot-autoconfigure/src/main/java/org/springframework/boot/autoconfigure/web/JspTemplateAvailabilityProvider.java b/spring-boot-autoconfigure/src/main/java/org/springframework/boot/autoconfigure/web/JspTemplateAvailabilityProvider.java index 1716995926..d07bf4a5ee 100755 --- a/spring-boot-autoconfigure/src/main/java/org/springframework/boot/autoconfigure/web/JspTemplateAvailabilityProvider.java +++ b/spring-boot-autoconfigure/src/main/java/org/springframework/boot/autoconfigure/web/JspTemplateAvailabilityProvider.java @@ -1,5 +1,5 @@ /* - * Copyright 2012-2015 the original author or authors. + * Copyright 2012-2016 the original author or authors. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. diff --git a/spring-boot-samples/spring-boot-sample-actuator-ui/src/test/java/org/springframework/boot/autoconfigure/web/JspTemplateAvailabilityProviderTest.java b/spring-boot-autoconfigure/src/test/java/org/springframework/boot/autoconfigure/web/JspTemplateAvailabilityProviderTests.java similarity index 75% rename from spring-boot-samples/spring-boot-sample-actuator-ui/src/test/java/org/springframework/boot/autoconfigure/web/JspTemplateAvailabilityProviderTest.java rename to spring-boot-autoconfigure/src/test/java/org/springframework/boot/autoconfigure/web/JspTemplateAvailabilityProviderTests.java index 206c3f45f8..34920cad91 100755 --- a/spring-boot-samples/spring-boot-sample-actuator-ui/src/test/java/org/springframework/boot/autoconfigure/web/JspTemplateAvailabilityProviderTest.java +++ b/spring-boot-autoconfigure/src/test/java/org/springframework/boot/autoconfigure/web/JspTemplateAvailabilityProviderTests.java @@ -1,5 +1,5 @@ /* - * Copyright 2012-2015 the original author or authors. + * Copyright 2012-2016 the original author or authors. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -17,7 +17,7 @@ package org.springframework.boot.autoconfigure.web; import org.junit.Test; -import org.springframework.boot.autoconfigure.template.TemplateAvailabilityProvider; + import org.springframework.core.io.DefaultResourceLoader; import org.springframework.core.io.ResourceLoader; import org.springframework.mock.env.MockEnvironment; @@ -30,8 +30,9 @@ import static org.junit.Assert.assertTrue; * * @author Yunkun Huang */ -public class JspTemplateAvailabilityProviderTest { - private final TemplateAvailabilityProvider provider = new JspTemplateAvailabilityProvider(); +public class JspTemplateAvailabilityProviderTests { + + private final JspTemplateAvailabilityProvider provider = new JspTemplateAvailabilityProvider(); private final ResourceLoader resourceLoader = new DefaultResourceLoader(); @@ -61,12 +62,4 @@ public class JspTemplateAvailabilityProviderTest { getClass().getClassLoader(), this.resourceLoader)); } - @Test - public void notAvailabilityOfTemplateWithCustomSuffixViaDeprecatedKey() { - this.environment.setProperty("spring.mvc.view.prefix", "classpath:/custom-templates/"); - this.environment.setProperty("spring.view.suffix", ".jsp"); - - assertFalse(this.provider.isTemplateAvailable("suffixed", this.environment, - getClass().getClassLoader(), this.resourceLoader)); - } } diff --git a/spring-boot-samples/spring-boot-sample-data-rest/src/test/resources/custom-templates/custom.jsp b/spring-boot-autoconfigure/src/test/resources/custom-templates/custom.jsp similarity index 100% rename from spring-boot-samples/spring-boot-sample-data-rest/src/test/resources/custom-templates/custom.jsp rename to spring-boot-autoconfigure/src/test/resources/custom-templates/custom.jsp diff --git a/spring-boot-samples/spring-boot-sample-data-rest/src/test/resources/custom-templates/suffixed.jsp b/spring-boot-autoconfigure/src/test/resources/custom-templates/suffixed.jsp similarity index 100% rename from spring-boot-samples/spring-boot-sample-data-rest/src/test/resources/custom-templates/suffixed.jsp rename to spring-boot-autoconfigure/src/test/resources/custom-templates/suffixed.jsp