Package org.apache.wicket.protocol.http.mock

Examples of org.apache.wicket.protocol.http.mock.MockServletContext


   *            the absolute path on disk to the web application's contents (e.g. war root) - may
   *            be <code>null</code>
   */
  public BaseWicketTester(final WebApplication application, String servletContextBasePath)
  {
    this(application, new MockServletContext(application, servletContextBasePath));
  }
View Full Code Here


   *            the servlet context used as backend
   */
  public BaseWicketTester(final WebApplication application, final ServletContext servletCtx)
  {
    servletContext = servletCtx != null ? servletCtx
      : new MockServletContext(application, null);

    final FilterConfig filterConfig = new TestFilterConfig();
    WicketFilter filter = new WicketFilter()
    {
      @Override
View Full Code Here

   *            the absolute path on disk to the web application's contents (e.g. war root) - may
   *            be <code>null</code>
   */
  public BaseWicketTester(final WebApplication application, String servletContextBasePath)
  {
    this(application, new MockServletContext(application, servletContextBasePath));
  }
View Full Code Here

   *            the servlet context used as backend
   */
  public BaseWicketTester(final WebApplication application, final ServletContext servletCtx)
  {
    servletContext = servletCtx != null ? servletCtx
      : new MockServletContext(application, null);

    final FilterConfig filterConfig = new TestFilterConfig();
    WicketFilter filter = new WicketFilter()
    {
      @Override
View Full Code Here

      return getClass().getName();
    }

    public ServletContext getServletContext()
    {
      return new MockServletContext(null, null);
    }
View Full Code Here

  public void setUp()
  {
    DummyApplication application = new DummyApplication();
    application.setName("dummyTestApplication");
    ThreadContext.setApplication(application);
    application.setServletContext(new MockServletContext(application, "/"));
    application.initApplication();
    errorCode = 0;
  }
View Full Code Here

    }

    @Override
    public ServletContext getServletContext()
    {
      return new MockServletContext(null, null);
    }
View Full Code Here

   *            the absolute path on disk to the web application's contents (e.g. war root) - may
   *            be <code>null</code>
   */
  public BaseWicketTester(final WebApplication application, String servletContextBasePath)
  {
    this(application, new MockServletContext(application, servletContextBasePath));
  }
View Full Code Here

   *            the servlet context used as backend
   */
  public BaseWicketTester(final WebApplication application, final ServletContext servletCtx)
  {
    servletContext = servletCtx != null ? servletCtx
      : new MockServletContext(application, null);

    final FilterConfig filterConfig = new TestFilterConfig();
    WicketFilter filter = new WicketFilter()
    {
      @Override
View Full Code Here

   */
  public void testLocalizer()
  {
    MockApplication dummy = new MockApplication();
    dummy.setName("test-app");
    dummy.setServletContext(new MockServletContext(dummy, ""));
    dummy.set();
    dummy.initApplication();
    Localizer localizer = dummy.getResourceSettings().getLocalizer();
    Assert.assertNotNull("Localizer should be available", localizer);
  }
View Full Code Here

TOP

Related Classes of org.apache.wicket.protocol.http.mock.MockServletContext

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.