Skip to content

Commit

Permalink
Tested docstring preservation
Browse files Browse the repository at this point in the history
  • Loading branch information
micheles committed Apr 5, 2021
1 parent 23d5735 commit fb8a321
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/tests/test.py
Expand Up @@ -137,10 +137,12 @@ def example(*args, **kw):

@example
def func(**kw):
"Docstring"
return kw

# there is no confusion when passing args as a keyword argument
self.assertEqual(func(args='a'), {'args': 'a'})
self.assertEqual(func.__doc__, "Docstring")

def test_decorator_factory(self):
# similar to what IPython is doing in traitlets.config.application
Expand Down

0 comments on commit fb8a321

Please sign in to comment.