@Test
public void testParseRewriteEntries() throws Exception
{
List<RewriteRule> rules = config.getGlobalRewriteRules();
RewriteRule r = rules.get(0);
assertEquals("^(.*[^/])$", r.getMatch());
assertEquals("$1/", r.getSubstitute());
assertEquals(Redirect.CHAIN, r.getRedirect());
assertTrue(r.isOutbound());
assertEquals(Case.IGNORE, r.getToCase());
assertEquals(TrailingSlash.IGNORE, r.getTrailingSlash());
r = rules.get(1);
assertEquals("", r.getMatch());
assertEquals("", r.getSubstitute());
assertEquals(Redirect.PERMANENT, r.getRedirect());
assertEquals(true, r.isOutbound());
assertEquals(Case.LOWERCASE, r.getToCase());
assertEquals(TrailingSlash.APPEND, r.getTrailingSlash());
r = rules.get(2);
assertEquals("", r.getMatch());
assertEquals("", r.getSubstitute());
assertEquals("http://www.google.com", r.getUrl());
assertEquals(Redirect.TEMPORARY, r.getRedirect());
assertEquals(false, r.isOutbound());
assertEquals(Case.UPPERCASE, r.getToCase());
assertEquals(TrailingSlash.REMOVE, r.getTrailingSlash());
}