clay.encodeEnd(facesContext);
//end the document
buffResponsewriter.endDocument();
Parser p = new Parser();
List nodes = p.parse(writer.getBuffer());
assertEquals("1 root node", 1, nodes.size());
Node comment = findComment((Node) nodes.get(0));
assertNotNull("comment found", comment);
assertTrue("is a comment", comment.isComment());