@Test public void testInvalidLexerCommand() {
		String[] pair = new String[] {
			"grammar A;\n" +
			"tokens{Foo}\n" +
			"b : Foo ;\n" +
			"X : 'foo1' -> popmode;\n" + // "meant" to use -> popMode
			"Y : 'foo2' -> token(Foo);", // "meant" to use -> type(Foo)

			"error(" + ErrorType.INVALID_LEXER_COMMAND.code + "): A.g4:4:14: lexer command popmode does not exist or is not supported by the current target\n" +
			"error(" + ErrorType.INVALID_LEXER_COMMAND.code + "): A.g4:5:14: lexer command token does not exist or is not supported by the current target\n"
		};
		testErrors(pair, true);
	}
This is a regression test for antlr/antlr4#190
"NullPointerException building lexer grammar using bogus 'token' action"
https://github.com/antlr/antlr4/issues/190
tool-testsuite/test/org/antlr/v4/test/tool/TestToolSyntaxErrors.java