Examples of MockRequestContext


Examples of org.springframework.webflow.test.MockRequestContext

   *
   * public String toString() { return "MyEnum " + name(); } }
   */

  public void testString() {
    Event event = factory.createResultEvent(this, "foobar", new MockRequestContext());
    assertEquals("foobar", event.getId());
  }
View Full Code Here

Examples of org.springframework.webflow.test.MockRequestContext

    assertEquals("foobar", event.getId());
  }

  public void testEvent() {
    Event orig = new Event(this, "test");
    Event event = factory.createResultEvent(this, orig, new MockRequestContext());
    assertSame(orig, event);
  }
View Full Code Here

Examples of org.springframework.webflow.test.MockRequestContext

    assertSame(orig, event);
  }

  public void testUnsupported() {
    try {
      factory.createResultEvent(this, new Date(), new MockRequestContext());
      fail();
    } catch (IllegalArgumentException e) {
      // expected
    }
  }
View Full Code Here

Examples of org.springframework.webflow.test.MockRequestContext

    MockHttpServletRequest request = new MockHttpServletRequest();
    request.setPathInfo("/fooFlow");
    request.setMethod("POST");
    request.addParameter("prop", "A");
    MockHttpServletResponse response = new MockHttpServletResponse();
    MockRequestContext context = new MockRequestContext();
    context.setExternalContext(new ServletExternalContext(new MockServletContext(), request, response));
    context.setAttribute("method", "bindAndValidate");

    // use a FormAction to do the binding
    FormAction formAction = new FormAction();
    formAction.setFormObjectClass(TestBean.class);
    formAction.setFormObjectName("formObject");
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.