mirror of
https://github.com/davidhalter/parso.git
synced 2025-12-07 05:14:29 +08:00
Show which keyword argument is repeated on 3.9+
This commit is contained in:
@@ -359,6 +359,10 @@ def test_continue_in_finally():
|
||||
]
|
||||
)
|
||||
def test_forbidden_name(template, target):
|
||||
assert _get_error_list(template.format(target=target), version="3")[0].message
|
||||
assert _get_error_list(template.format(target=target), version="3")
|
||||
|
||||
|
||||
def test_repeated_kwarg():
|
||||
# python 3.9+ shows which argument is repeated
|
||||
assert "q" not in _get_error_list("f(q=1, q=2)", version="3.8")[0].message
|
||||
assert "q" in _get_error_list("f(q=1, q=2)", version="3.9")[0].message
|
||||
|
||||
Reference in New Issue
Block a user