@Test
public void testRange() {

  assertEquals(1, Patterns.range('a', 'c').match("a", 0, 1));
  assertEquals(1, Patterns.range('a', 'c').match("b", 0, 1));
  assertEquals(1, Patterns.range('a', 'c').match("c", 0, 1));
  assertEquals(1, Patterns.range('a', 'c').match("abc", 0, 1));
  assertEquals(1, Patterns.range('a', 'c').match("ba", 1, 2));
  assertEquals(MISMATCH, Patterns.range('a', 'c').match("d", 0, 1));
  assertEquals(MISMATCH, Patterns.range('a', 'c').match("0", 0, 1));
  assertEquals(MISMATCH, Patterns.range('a', 'c').match("a", 0, 0));
  assertEquals(MISMATCH, Patterns.range('a', 'c').match("a", 0, 0));
}