### Question:
PortletRequest extends AbstractClientRequest { @Override public OutputStream getOutputStream() throws IOException { return responseDelegate.getOutputStream(); } PortletRequest(ApplicationContext applicationContext,
            PortletContext context, javax.portlet.PortletRequest request,
            PortletResponse response, RequestDelegate requestDelegate, ResponseDelegate responseDelegate); javax.portlet.PortletRequest getRequest(); PortletResponse getResponse(); PortletContext getPortletContext(); Map<String, String> getHeader(); Addable<String> getResponseHeaders(); Map<String, String[]> getHeaderValues(); Map<String, Object> getRequestScope(); Map<String, Object> getSessionScope(); Map<String, Object> getPortletSessionScope(); @Override List<String> getAvailableScopes(); Locale getRequestLocale(); @Override Map<String, String> getParam(); @Override Map<String, String[]> getParamValues(); boolean isUserInRole(String role); @Override OutputStream getOutputStream(); @Override PrintWriter getPrintWriter(); @Override Writer getWriter(); @Override boolean isResponseCommitted(); @Override void setContentType(String contentType); void doForward(String path); void doInclude(String path); @Override Map<String, Object> getContext(String scope);  }### Answer:
@Test public void testGetOutputStream() throws IOException { ServletOutputStream os = createMock(ServletOutputStream.class); expect(responseDelegate.getOutputStream()).andReturn(os); replay(applicationContext, request, response, os, portletContext, requestDelegate, responseDelegate); assertEquals(req.getOutputStream(), os); verify(applicationContext, request, response, os, portletContext, requestDelegate, responseDelegate); }