diff options
Diffstat (limited to 'tests')
-rw-r--r-- | tests/test_scoped_nodes.py | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/tests/test_scoped_nodes.py b/tests/test_scoped_nodes.py index 63fe0af7..705f5d2d 100644 --- a/tests/test_scoped_nodes.py +++ b/tests/test_scoped_nodes.py @@ -2883,7 +2883,11 @@ def test_deprecation_of_doc_attribute() -> None: node_class.postinit(bases=[], body=[], decorators=[], doc_node=doc_node) assert node_class.doc_node == doc_node node_func = nodes.FunctionDef(name="MyFunction") - node_func.postinit(args=nodes.Arguments(), body=[], doc_node=doc_node) + node_func.postinit( + args=nodes.Arguments(parent=node_func, vararg=None, kwarg=None), + body=[], + doc_node=doc_node, + ) assert node_func.doc_node == doc_node # Test 'doc' attribute if only 'doc_node' is passed |