Commit 728829ba authored by Phillip Webb's avatar Phillip Webb

Revert welcome file defaults

Revert welcome file default that break existing tests.

Issue: #54228642
parent c9519894
...@@ -8,6 +8,7 @@ import java.util.concurrent.TimeUnit; ...@@ -8,6 +8,7 @@ import java.util.concurrent.TimeUnit;
import org.junit.AfterClass; import org.junit.AfterClass;
import org.junit.BeforeClass; import org.junit.BeforeClass;
import org.junit.Ignore;
import org.junit.Test; import org.junit.Test;
import org.springframework.boot.SpringApplication; import org.springframework.boot.SpringApplication;
import org.springframework.context.ConfigurableApplicationContext; import org.springframework.context.ConfigurableApplicationContext;
...@@ -26,6 +27,8 @@ import static org.junit.Assert.assertTrue; ...@@ -26,6 +27,8 @@ import static org.junit.Assert.assertTrue;
* *
* @author Dave Syer * @author Dave Syer
*/ */
@Ignore
// FIXME See #54228642
public class SampleWebStaticApplicationTests { public class SampleWebStaticApplicationTests {
private static ConfigurableApplicationContext context; private static ConfigurableApplicationContext context;
......
...@@ -120,7 +120,6 @@ public class JettyEmbeddedServletContainerFactory extends ...@@ -120,7 +120,6 @@ public class JettyEmbeddedServletContainerFactory extends
ServletContextInitializer[] initializersToUse = mergeInitializers(initializers); ServletContextInitializer[] initializersToUse = mergeInitializers(initializers);
Configuration[] configurations = getWebAppContextConfigurations(context, Configuration[] configurations = getWebAppContextConfigurations(context,
initializersToUse); initializersToUse);
context.setWelcomeFiles(new String[] { "index.html" });
context.setConfigurations(configurations); context.setConfigurations(configurations);
context.getSessionHandler().getSessionManager() context.getSessionHandler().getSessionManager()
.setMaxInactiveInterval(getSessionTimeout()); .setMaxInactiveInterval(getSessionTimeout());
......
...@@ -139,7 +139,6 @@ public class TomcatEmbeddedServletContainerFactory extends ...@@ -139,7 +139,6 @@ public class TomcatEmbeddedServletContainerFactory extends
File docBase = getValidDocumentRoot(); File docBase = getValidDocumentRoot();
docBase = (docBase != null ? docBase : createTempDir("tomcat-docbase")); docBase = (docBase != null ? docBase : createTempDir("tomcat-docbase"));
Context context = new StandardContext(); Context context = new StandardContext();
context.addWelcomeFile("index.html");
context.setName(getContextPath()); context.setName(getContextPath());
context.setPath(getContextPath()); context.setPath(getContextPath());
context.setDocBase(docBase.getAbsolutePath()); context.setDocBase(docBase.getAbsolutePath());
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment