Commit 5704109b authored by Stefan Behnel's avatar Stefan Behnel

Extend a test.

parent 8cef4203
......@@ -139,6 +139,18 @@ def wrap_modify_mix(f):
>>> wrapped(a=2, test=3)
CALLED
(2, 1)
>>> def py_modify(**kwargs):
... print(kwargs)
... kwargs['new'] = len(kwargs)
... return kwargs
>>> wrapped_modify = wrap_modify_mix(py_modify)
>>> wrapped_modify(a=1)
CALLED
{'a': 1}
{'a': 1, 'test': 1}
{'a': 1, 'test': 1, 'new': 2}
"""
def wrapper(*args, **kwargs):
print("CALLED")
......
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