mirror of
https://github.com/davidhalter/parso.git
synced 2025-12-08 05:34:51 +08:00
Fix a Python 2.7 issue
This commit is contained in:
@@ -37,7 +37,8 @@ def test_python_exception_matches(code):
|
|||||||
error, = errors
|
error, = errors
|
||||||
actual = error.message
|
actual = error.message
|
||||||
assert actual in wanted
|
assert actual in wanted
|
||||||
assert line_nr == error.start_pos[0]
|
# Somehow in Python2.7 the SyntaxError().lineno is sometimes None
|
||||||
|
assert line_nr is None or line_nr == error.start_pos[0]
|
||||||
|
|
||||||
|
|
||||||
def test_non_async_in_async():
|
def test_non_async_in_async():
|
||||||
|
|||||||
Reference in New Issue
Block a user