@Test
public void testEscapeSubBuffer() throws Exception
{

    // Test a sub-part of the buffer (i.e. positions 1 and 2).
    StringWriter writer = new StringWriter();
    escapeHandler.escape(TEST_BUFFER.toCharArray(), 1, 2, true, writer);
    assertEquals("&lt;&gt;", writer.toString());
}