Kaydet (Commit) 50a26147 authored tarafından Yury Selivanov's avatar Yury Selivanov

Issue #24791: More tests in test_parser

üst 14acf5f4
...@@ -350,9 +350,11 @@ class RoundtripLegalSyntaxTestCase(unittest.TestCase): ...@@ -350,9 +350,11 @@ class RoundtripLegalSyntaxTestCase(unittest.TestCase):
self.check_expr('{**{}, 3:4, **{5:6, 7:8}}') self.check_expr('{**{}, 3:4, **{5:6, 7:8}}')
def test_argument_unpacking(self): def test_argument_unpacking(self):
self.check_expr("f(*a, **b)")
self.check_expr('f(a, *b, *c, *d)') self.check_expr('f(a, *b, *c, *d)')
self.check_expr('f(**a, **b)') self.check_expr('f(**a, **b)')
self.check_expr('f(2, *a, *b, **b, **c, **d)') self.check_expr('f(2, *a, *b, **b, **c, **d)')
self.check_expr("f(*b, *() or () and (), **{} and {}, **() or {})")
def test_set_comprehensions(self): def test_set_comprehensions(self):
self.check_expr('{x for x in seq}') self.check_expr('{x for x in seq}')
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment