assertEquals("finished44", renderResponse.getContentAsString());
}
public void testSimpleFormSubmissionWithValidationError() throws Exception {
MockActionRequest actionRequest = new MockActionRequest();
MockActionResponse actionResponse = new MockActionResponse();
actionRequest.setParameter("action", "form");
actionRequest.setParameter("age", "XX");
simpleDispatcherPortlet.processAction(actionRequest, actionResponse);
MockRenderRequest renderRequest = new MockRenderRequest();
MockRenderResponse renderResponse = new MockRenderResponse();
renderRequest.setSession(actionRequest.getPortletSession());
renderRequest.setParameters(actionResponse.getRenderParameterMap());
renderRequest.setParameter("action", "form");
simpleDispatcherPortlet.doDispatch(renderRequest, renderResponse);
assertEquals("5", renderResponse.getContentAsString());
}