diff options
Diffstat (limited to 'uitest/src')
-rw-r--r-- | uitest/src/com/vaadin/launcher/ApplicationRunnerServlet.java | 7 | ||||
-rw-r--r-- | uitest/src/com/vaadin/tests/util/SampleDirectory.java | 8 |
2 files changed, 9 insertions, 6 deletions
diff --git a/uitest/src/com/vaadin/launcher/ApplicationRunnerServlet.java b/uitest/src/com/vaadin/launcher/ApplicationRunnerServlet.java index 11685033a9..3d63c7dfb9 100644 --- a/uitest/src/com/vaadin/launcher/ApplicationRunnerServlet.java +++ b/uitest/src/com/vaadin/launcher/ApplicationRunnerServlet.java @@ -21,7 +21,6 @@ import java.net.MalformedURLException; import java.net.URL; import java.util.Collections; import java.util.LinkedHashSet; -import java.util.Properties; import java.util.logging.Level; import java.util.logging.Logger; @@ -32,6 +31,7 @@ import javax.servlet.http.HttpServletResponse; import com.vaadin.Application; import com.vaadin.server.AbstractUIProvider; +import com.vaadin.server.ApplicationConfiguration; import com.vaadin.server.VaadinServlet; import com.vaadin.server.WrappedHttpServletRequest; import com.vaadin.server.WrappedRequest; @@ -259,8 +259,9 @@ public class ApplicationRunnerServlet extends VaadinServlet { @Override protected ServletDeploymentConfiguration createDeploymentConfiguration( - Properties applicationProperties) { - return new ServletDeploymentConfiguration(this, applicationProperties) { + ApplicationConfiguration applicationConfiguration) { + return new ServletDeploymentConfiguration(this, + applicationConfiguration) { @Override public String getStaticFileLocation(WrappedRequest request) { URIS uris = getApplicationRunnerURIs(WrappedHttpServletRequest diff --git a/uitest/src/com/vaadin/tests/util/SampleDirectory.java b/uitest/src/com/vaadin/tests/util/SampleDirectory.java index ef20da788d..e15f0ccfe3 100644 --- a/uitest/src/com/vaadin/tests/util/SampleDirectory.java +++ b/uitest/src/com/vaadin/tests/util/SampleDirectory.java @@ -52,8 +52,10 @@ public class SampleDirectory { // cannot access example directory, possible security issue with // Application Server or Servlet Container // Try to read sample directory from web.xml parameter - if (application.getProperty("sampleDirectory") != null) { - file = new File(application.getProperty("sampleDirectory")); + String sampleDirProperty = application.getConfiguration() + .getInitParameters().getProperty("sampleDirectory"); + if (sampleDirProperty != null) { + file = new File(sampleDirProperty); if ((file != null) && (file.canRead()) && (file.getAbsolutePath() != null)) { // Success using property @@ -61,7 +63,7 @@ public class SampleDirectory { } // Failure using property errorMessage += "Failed also to access sample directory <b>[" - + application.getProperty("sampleDirectory") + + sampleDirProperty + "]</b> defined in <b>sampleDirectory property</b>."; } else { // Failure using application context base dir, no property set |