Examples of FlowException


Examples of org.springframework.webflow.core.FlowException

    EasyMock.verify(new Object[] { flowExecutor });
  }

  public void testHandleFlowExceptionCustomFlowHandler() throws Exception {
    handleException = true;
    final FlowException flowException = new FlowException("Error") {
    };
    renderRequest.setContextPath("/springtravel");
    flowExecutor.launchExecution("foo", flowInput, renderContext);
    EasyMock.expectLastCall().andThrow(flowException);
    EasyMock.replay(new Object[] { flowExecutor });
View Full Code Here

Examples of org.springframework.webflow.core.FlowException

  }

  public void testHandleFlowExceptionFromSession() throws Exception {
    handleException = true;
    PortletSession session = renderRequest.getPortletSession();
    final FlowException flowException = new FlowException("Error") {
    };
    session.setAttribute("actionRequestFlowException", flowException);
    ModelAndView mv = controller.handleRender(renderRequest, renderResponse, flowHandler);
    assertEquals("error", mv.getViewName());
  }
View Full Code Here

Examples of org.springframework.webflow.core.FlowException

  public void testDefaultHandleFlowException() throws Exception {
    setupRequest("/springtravel", "/app", "/foo", "GET");
    Map<String, String> parameters = new HashMap<String, String>();
    request.setParameters(parameters);
    flowExecutor.launchExecution("foo", flowInput, context);
    FlowException flowException = new FlowException("Error") {
    };
    EasyMock.expectLastCall().andThrow(flowException);
    EasyMock.replay(new Object[] { flowExecutor });
    try {
      flowHandlerAdapter.handle(request, response, flowHandler);
View Full Code Here

Examples of org.springframework.webflow.core.FlowException

  public void testDefaultHandleNoSuchFlowExecutionException() throws Exception {
    setupRequest("/springtravel", "/app", "/foo", "GET");
    request.addParameter("execution", "12345");
    flowExecutor.resumeExecution("12345", context);
    FlowException flowException = new NoSuchFlowExecutionException(new MockFlowExecutionKey("12345"), null);
    EasyMock.expectLastCall().andThrow(flowException);
    EasyMock.replay(new Object[] { flowExecutor });
    flowHandlerAdapter.handle(request, response, flowHandler);
    assertEquals("/springtravel/app/foo", response.getRedirectedUrl());
    EasyMock.verify(new Object[] { flowExecutor });
View Full Code Here

Examples of org.springframework.webflow.core.FlowException

  public void testDefaultHandleNoSuchFlowExecutionExceptionAjaxRequest() throws Exception {
    setupRequest("/springtravel", "/app", "/foo", "GET");
    request.addParameter("execution", "12345");
    flowExecutor.resumeExecution("12345", context);
    FlowException flowException = new NoSuchFlowExecutionException(new MockFlowExecutionKey("12345"), null);
    EasyMock.expectLastCall().andThrow(flowException);
    EasyMock.replay(new Object[] { flowExecutor });
    context.setAjaxRequest(true);
    request.addHeader("Accept", "text/html;type=ajax");
    flowHandlerAdapter.handle(request, response, flowHandler);
View Full Code Here

Examples of org.springframework.webflow.core.FlowException

    EasyMock.verify(new Object[] { flowExecutor });
  }

  public void testHandleFlowExceptionCustomFlowHandler() throws Exception {
    handleException = true;
    final FlowException flowException = new FlowException("Error") {
    };
    setupRequest("/springtravel", "/app", "/foo", "GET");
    flowExecutor.launchExecution("foo", flowInput, context);
    EasyMock.expectLastCall().andThrow(flowException);
    EasyMock.replay(new Object[] { flowExecutor });
View Full Code Here

Examples of org.springframework.webflow.core.FlowException

    request.setServletPath("/app");
    request.setPathInfo("/foo");
    request.setRequestURI("/springtravel/app/foo");
    request.setMethod("GET");
    executor.launchExecution("foo", null, context);
    FlowException flowException = new FlowException("Error") {
    };
    EasyMock.expectLastCall().andThrow(flowException);
    EasyMock.replay(new Object[] { executor });
    try {
      controller.handleRequest(request, response);
View Full Code Here

Examples of org.springframework.webflow.core.FlowException

    request.setPathInfo("/foo");
    request.setRequestURI("/springtravel/app/foo");
    request.setMethod("GET");
    request.addParameter("execution", "12345");
    executor.resumeExecution("12345", context);
    FlowException flowException = new NoSuchFlowExecutionException(new MockFlowExecutionKey("12345"), null);
    EasyMock.expectLastCall().andThrow(flowException);
    EasyMock.replay(new Object[] { executor });
    ModelAndView mv = controller.handleRequest(request, response);
    assertNull(mv);
    assertEquals("/springtravel/app/foo", response.getRedirectedUrl());
View Full Code Here

Examples of org.springframework.webflow.core.FlowException

    assertEquals("/springtravel/app/foo?bar=baz", response.getRedirectedUrl());
    EasyMock.verify(new Object[] { executor });
  }

  public void testHandleFlowExceptionCustomFlowHandler() throws Exception {
    final FlowException flowException = new FlowException("Error") {
    };

    controller.registerFlowHandler(new FlowHandler() {
      public String getFlowId() {
        return "foo";
View Full Code Here

Examples of org.springframework.webflow.core.FlowException

  public ModelAndView handleRender(RenderRequest request, RenderResponse response, Object handler) throws Exception {
    FlowHandler flowHandler = (FlowHandler) handler;
    checkAndPrepare(request, response);
    populateConveniencePortletProperties(request);
    FlowException e = clearActionRequestFlowException(request, response, flowHandler);
    if (e != null) {
      return handleException(e, flowHandler, request, response);
    }
    String flowExecutionKey = flowUrlHandler.getFlowExecutionKey(request);
    if (flowExecutionKey != null) {
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.