@Test
public void testToken() {

  Token token = new Token(1, 1, 'a');
  expect(fromToken.map(token)).andReturn(2);
  replay();
  Parser<Integer> parser = Parsers.token(fromToken);
  assertEquals(fromToken.toString(), parser.toString());
  assertEquals((Object) 2, parser.from(Parsers.constant(token).times(1)).parse("", mode));
}