Closed Tishj closed 1 year ago
This is overcomplicated, we can just consume from the Lexer normally and just not parse in those tests
I guess this was already done but I'll add some more functionality:
parameterized tests and some SECTIONS + implementing the << operator in branch 7-lexing-implementation
makes it much nicer to test/debug
What I envision is that we wrap the Lexer in a class that gets a copy of all produced tokens before sending it on. This class also implements TokenProvider so the Parser is none the wiser.
Then we can create a set of expected tokens and assert in a test that the lexer produces these tokens.