self.func(*args, **kwargs)
@Wrapper
-def test_look_in_unwrapped():
+def wrapped():
"""
Docstrings in wrapped functions must be detected as well.
'one other test'
"""
+def test_look_in_unwrapped():
+ """
+ Ensure that wrapped doctests work correctly.
+
+ >>> import doctest
+ >>> doctest.run_docstring_examples(
+ ... wrapped, {}, name=wrapped.__name__, verbose=True)
+ Finding tests in wrapped
+ Trying:
+ 'one other test'
+ Expecting:
+ 'one other test'
+ ok
+ """
+
@doctest_skip_if(support.check_impl_detail(cpython=False))
def test_wrapped_c_func():
"""