void (String text, String expected) { ManifestLexer lexer = new ManifestLexer(); lexer.start(text); StringBuilder actual = new StringBuilder(); IElementType token; while ((token = lexer.getTokenType()) != null) { actual.append(token).append(" ('").append(lexer.getTokenText()).append("')\n"); lexer.advance(); } assertEquals(expected.trim(), actual.toString().trim()); }