summaryrefslogtreecommitdiff
path: root/tests/test_ext_autodoc_configs.py
diff options
context:
space:
mode:
Diffstat (limited to 'tests/test_ext_autodoc_configs.py')
-rw-r--r--tests/test_ext_autodoc_configs.py24
1 files changed, 24 insertions, 0 deletions
diff --git a/tests/test_ext_autodoc_configs.py b/tests/test_ext_autodoc_configs.py
index a9af8a272..b90772f6e 100644
--- a/tests/test_ext_autodoc_configs.py
+++ b/tests/test_ext_autodoc_configs.py
@@ -482,9 +482,17 @@ def test_autodoc_typehints_signature(app):
' :module: target.typehints',
' ',
' ',
+ ' .. py:method:: Math.horse(a: str, b: int) -> None',
+ ' :module: target.typehints',
+ ' ',
+ ' ',
' .. py:method:: Math.incr(a: int, b: int = 1) -> int',
' :module: target.typehints',
' ',
+ ' ',
+ ' .. py:method:: Math.nothing() -> None',
+ ' :module: target.typehints',
+ ' ',
'',
'.. py:function:: complex_func(arg1: str, arg2: List[int], arg3: Tuple[int, '
'Union[str, Unknown]] = None, *args: str, **kwargs: str) -> None',
@@ -497,6 +505,10 @@ def test_autodoc_typehints_signature(app):
'',
'.. py:function:: incr(a: int, b: int = 1) -> int',
' :module: target.typehints',
+ '',
+ '',
+ '.. py:function:: missing_attr(c, a: str, b: Optional[str] = None) -> str',
+ ' :module: target.typehints',
''
]
@@ -521,9 +533,17 @@ def test_autodoc_typehints_none(app):
' :module: target.typehints',
' ',
' ',
+ ' .. py:method:: Math.horse(a, b)',
+ ' :module: target.typehints',
+ ' ',
+ ' ',
' .. py:method:: Math.incr(a, b=1)',
' :module: target.typehints',
' ',
+ ' ',
+ ' .. py:method:: Math.nothing()',
+ ' :module: target.typehints',
+ ' ',
'',
'.. py:function:: complex_func(arg1, arg2, arg3=None, *args, **kwargs)',
' :module: target.typehints',
@@ -535,6 +555,10 @@ def test_autodoc_typehints_none(app):
'',
'.. py:function:: incr(a, b=1)',
' :module: target.typehints',
+ '',
+ '',
+ '.. py:function:: missing_attr(c, a, b=None)',
+ ' :module: target.typehints',
''
]