diff options
author | Yury Selivanov <yselivanov@sprymix.com> | 2014-09-26 21:34:54 (GMT) |
---|---|---|
committer | Yury Selivanov <yselivanov@sprymix.com> | 2014-09-26 21:34:54 (GMT) |
commit | 081bbf6b28868774c1abca0a8469a517abb9f6cc (patch) | |
tree | 5a91ca676029cceeda75c4a73d2afe77696b4301 /Lib/test/test_inspect.py | |
parent | 2c0a91606105e1606d886c198ea7ed1b195c692f (diff) | |
download | cpython-081bbf6b28868774c1abca0a8469a517abb9f6cc.zip cpython-081bbf6b28868774c1abca0a8469a517abb9f6cc.tar.gz cpython-081bbf6b28868774c1abca0a8469a517abb9f6cc.tar.bz2 |
inspect: Fix getsource() to support decorated functions.
Issue #1764286. Patch by Claudiu Popa.
Diffstat (limited to 'Lib/test/test_inspect.py')
-rw-r--r-- | Lib/test/test_inspect.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/Lib/test/test_inspect.py b/Lib/test/test_inspect.py index 6da5822..1da88c4 100644 --- a/Lib/test/test_inspect.py +++ b/Lib/test/test_inspect.py @@ -377,6 +377,9 @@ class TestDecorators(GetSourceBase): def test_replacing_decorator(self): self.assertSourceEqual(mod2.gone, 9, 10) + def test_getsource_unwrap(self): + self.assertSourceEqual(mod2.real, 122, 124) + class TestOneliners(GetSourceBase): fodderModule = mod2 def test_oneline_lambda(self): |