MockRenderRequest request = new MockRenderRequest(PortletMode.VIEW);
MockRenderResponse response = new MockRenderResponse();
portlet.render(request, response);
assertEquals("myView", response.getContentAsString());
MockActionRequest actionRequest = new MockActionRequest("this");
MockActionResponse actionResponse = new MockActionResponse();
portlet.processAction(actionRequest, actionResponse);
request = new MockRenderRequest(PortletMode.VIEW, WindowState.MAXIMIZED);
request.setParameters(actionResponse.getRenderParameterMap());
response = new MockRenderResponse();
portlet.render(request, response);
assertEquals("myLargeView-value", response.getContentAsString());
actionRequest = new MockActionRequest("that");
actionResponse = new MockActionResponse();
portlet.processAction(actionRequest, actionResponse);
request = new MockRenderRequest(PortletMode.VIEW, WindowState.MAXIMIZED);
request.setParameters(actionResponse.getRenderParameterMap());
response = new MockRenderResponse();
portlet.render(request, response);
assertEquals("myLargeView-value2", response.getContentAsString());
actionRequest = new MockActionRequest("else");
actionResponse = new MockActionResponse();
portlet.processAction(actionRequest, actionResponse);
request = new MockRenderRequest(PortletMode.VIEW, WindowState.MAXIMIZED);
request.setParameters(actionResponse.getRenderParameterMap());
response = new MockRenderResponse();
portlet.render(request, response);
assertEquals("myLargeView-value3", response.getContentAsString());
actionRequest = new MockActionRequest("error");
actionResponse = new MockActionResponse();
portlet.processAction(actionRequest, actionResponse);
request = new MockRenderRequest(PortletMode.VIEW, WindowState.MAXIMIZED);
request.setParameters(actionResponse.getRenderParameterMap());
request.setSession(actionRequest.getPortletSession());
response = new MockRenderResponse();
portlet.render(request, response);
assertEquals("XXX", response.getContentAsString());
MockEventRequest eventRequest = new MockEventRequest(new MockEvent("event1"));