lexer: Add test cases for errors.