<servlet>
<servlet-name>default</servlet-name>
- <servlet-class>org.eclipse.jetty.servlet.DefaultServlet</servlet-class>
+ <servlet-class>org.apache.catalina.servlets.DefaultServlet</servlet-class>
</servlet>
@Test
public void testStaticContent() throws Exception {
- WebResponse response = executeRequest("http://localhost:8080/default.css");
+ WebResponse response = executeRequest("http://localhost:8080/static/page.html");
log.info("Title:\t\t{}", response.getTitle());
log.debug("Text:\t\t{}", response.getText());
}
--- /dev/null
+package org.apache.catalina.servlets;
+
+import javax.servlet.http.HttpServlet;
+
+/**
+ * Möglichst simple Fake-Implementierung für die Ausführung des Testfalls
+ *
+ * @author kai
+ */
+public class DefaultServlet extends HttpServlet {
+
+}
import java.util.Enumeration;
import javax.servlet.http.HttpServletRequest;
import org.junit.Before;
-import org.eclipse.jetty.servlet.DefaultServlet;
import org.slf4j.Logger;
import org.slf4j.LoggerFactory;
@Before
public void init() throws Exception {
sr = new ServletRunner(config, ""); // Dies ist der einzige Konstruktor, der die Context-Root der Webapp im Testfall korrekt initialisiert :/
- sr.registerServlet("default", DefaultServlet.class.getName());
client = sr.newClient();
}