|
|
@ -574,6 +574,25 @@ public class ServerPropertiesTests {
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@Test
|
|
|
|
|
|
|
|
public void customTomcatDisableMaxHttpPostSize() {
|
|
|
|
|
|
|
|
Map<String, String> map = new HashMap<String, String>();
|
|
|
|
|
|
|
|
map.put("server.tomcat.max-http-post-size", "-1");
|
|
|
|
|
|
|
|
bindProperties(map);
|
|
|
|
|
|
|
|
TomcatEmbeddedServletContainerFactory container = new TomcatEmbeddedServletContainerFactory(0);
|
|
|
|
|
|
|
|
this.properties.customize(container);
|
|
|
|
|
|
|
|
TomcatEmbeddedServletContainer embeddedContainer =
|
|
|
|
|
|
|
|
(TomcatEmbeddedServletContainer) container.getEmbeddedServletContainer();
|
|
|
|
|
|
|
|
embeddedContainer.start();
|
|
|
|
|
|
|
|
try {
|
|
|
|
|
|
|
|
assertThat(embeddedContainer.getTomcat().getConnector().getMaxPostSize())
|
|
|
|
|
|
|
|
.isEqualTo(-1);
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
finally {
|
|
|
|
|
|
|
|
embeddedContainer.stop();
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
@Test
|
|
|
|
@Test
|
|
|
|
@Deprecated
|
|
|
|
@Deprecated
|
|
|
|
public void customTomcatMaxHttpPostSizeWithDeprecatedProperty() {
|
|
|
|
public void customTomcatMaxHttpPostSizeWithDeprecatedProperty() {
|
|
|
|