def test_no_keyword(self): self.assertIsNone(lexer.lex_result(self.tok('thing')))
def test_rest(self): self.assertEqual({ 'keyword': lexer.Token('K', ':raw', at(1, 1)), 'rest': lexer.Token('S', ' stuff', at(1, 5)), }, lexer.lex_result(self.tok(':raw stuff')))