public void testReplacesTextContentMatchedByRegularExpression() throws IOException {
HTMLProcessor processor = createProcessor("<hello>Today is DATE so hi</hello>");
processor.addTextFilter(new RegexReplacementTextFilter("DATE", "1-jan-2009"));
processor.process();
assertEquals("<hello>Today is 1-jan-2009 so hi</hello>", body.build().getStringContent());
}
public void testAllowsMatchedGroupToBeUsedInSubsitution() throws IOException {
HTMLProcessor processor = createProcessor("<hello>I think JIRA:SIM-1234 is the way forward</hello>");