@Test
void getDirective() throws InvalidVelocityException
{

    VelocityParserContext context = new VelocityParserContext();
    StringBuffer buffer = new StringBuffer();
    int index = this.parser.getDirective("#if($a==1)true enough#elseno way!#end".toCharArray(), 0, buffer, context);
    assertEquals("#if($a==1)".length(), index);
    assertEquals("#if($a==1)", buffer.toString());
    assertTrue(context.isInVelocityBlock());
}