Include function return type annotation in docstring if it is present

This commit is contained in:
Dima Gerasimov authored and Dave Halter committed 2018-04-23 21:20:21 +02:00
1 parent 88243d2408
commit ceb5509170
3 files changed
+8 -2

No files matched your search

@@ -75,7 +75,8 @@ def test_hex_values_in_docstring():
@pytest.mark.parametrize(
'code,call_signature', [
('def my_function(x, y, z) -> str:\n return', 'my_function(x, y, z)'),
('def my_function(x, typed: Type, z):\n return', 'my_function(x, typed: Type, z)'),
('def my_function(x, y, z) -> str:\n return', 'my_function(x, y, z) -> str'),
('lambda x, y, z: x + y * z\n', '<lambda>(x, y, z)')
])
def test_get_call_signature(code, call_signature):