use of org.springframework.web.filter.CharacterEncodingFilter in project spring-boot by spring-projects.
the class HttpEncodingAutoConfigurationTests method forceRequest.
@Test
public void forceRequest() throws Exception {
load(EmptyConfiguration.class, "spring.http.encoding.force-request:false");
CharacterEncodingFilter filter = this.context.getBean(CharacterEncodingFilter.class);
assertCharacterEncodingFilter(filter, "UTF-8", false, false);
}
use of org.springframework.web.filter.CharacterEncodingFilter in project spring-boot by spring-projects.
the class HttpEncodingAutoConfigurationTests method customConfiguration.
@Test
public void customConfiguration() {
load(EmptyConfiguration.class, "spring.http.encoding.charset:ISO-8859-15", "spring.http.encoding.force:false");
CharacterEncodingFilter filter = this.context.getBean(CharacterEncodingFilter.class);
assertCharacterEncodingFilter(filter, "ISO-8859-15", false, false);
}
use of org.springframework.web.filter.CharacterEncodingFilter in project spring-boot by spring-projects.
the class HttpEncodingAutoConfigurationTests method defaultConfiguration.
@Test
public void defaultConfiguration() {
load(EmptyConfiguration.class);
CharacterEncodingFilter filter = this.context.getBean(CharacterEncodingFilter.class);
assertCharacterEncodingFilter(filter, "UTF-8", true, false);
}
use of org.springframework.web.filter.CharacterEncodingFilter in project spring-boot by spring-projects.
the class HttpEncodingAutoConfigurationTests method forceResponseOverridesForce.
@Test
public void forceResponseOverridesForce() throws Exception {
load(EmptyConfiguration.class, "spring.http.encoding.force:true", "spring.http.encoding.force-response:false");
CharacterEncodingFilter filter = this.context.getBean(CharacterEncodingFilter.class);
assertCharacterEncodingFilter(filter, "UTF-8", true, false);
}
use of org.springframework.web.filter.CharacterEncodingFilter in project spring-boot by spring-projects.
the class HttpEncodingAutoConfigurationTests method forceResponse.
@Test
public void forceResponse() throws Exception {
load(EmptyConfiguration.class, "spring.http.encoding.force-response:true");
CharacterEncodingFilter filter = this.context.getBean(CharacterEncodingFilter.class);
assertCharacterEncodingFilter(filter, "UTF-8", true, true);
}
Aggregations