ResponseRendererImpl implements ResponseRenderer { public void renderPageMarkupResponse(String pageName) throws IOException { Page page = pageCache.get(pageName); renderer.renderPageResponse(page); } ResponseRendererImpl(RequestPageCache pageCache, PageContentTypeAnalyzer pageContentAnalyzer,
            PageResponseRenderer renderer); ContentType findContentType(Object component); void renderPageMarkupResponse(String pageName);  }
@Test public void render_page_markup() throws Exception { RequestPageCache cache = mockRequestPageCache(); PageContentTypeAnalyzer analyzer = mockPageContentTypeAnalyzer(); String pageName = "foo/bar"; Page page = mockPage(); PageResponseRenderer pageResponseRenderer = mockPageResponseRenderer(); Response response = mockResponse(); train_get(cache, pageName, page); pageResponseRenderer.renderPageResponse(page); replay(); ResponseRenderer renderer = new ResponseRendererImpl(cache, analyzer, pageResponseRenderer); renderer.renderPageMarkupResponse(pageName); verify(); }