mirror of
https://github.com/davidhalter/parso.git
synced 2026-10-15 10:32:39 +08:00
Fix a prefix issue with error leafs.
This commit is contained in:
1 parent
579146b501
commit
f20106d88e
2 files changed
+21
-6
No files matched your search
@@ -227,3 +227,11 @@ def test_endmarker_end_pos():
|
||||
def test_indentation(code, types):
|
||||
actual_types = [t.type for t in _get_token_list(code)]
|
||||
assert actual_types == types + [ENDMARKER]
|
||||
|
||||
|
||||
def test_error_string():
|
||||
t1, endmarker = _get_token_list(' "\n')
|
||||
assert t1.type == ERRORTOKEN
|
||||
assert t1.prefix == ' '
|
||||
assert t1.string == '"\n'
|
||||
assert endmarker.string == ''
|
||||
Reference in new issue
Block a user