Skip to content

Commit 3e64600

Browse files
committed
Incorporate target_name into test suite.
1 parent 1aa1bbd commit 3e64600

File tree

2 files changed

+9
-0
lines changed

2 files changed

+9
-0
lines changed

numpydoc/docscrape.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -308,6 +308,10 @@ def parse_item_name(text):
308308
self._error_location(f"Error parsing See Also entry {line!r}")
309309
role = m.group("role")
310310
name = m.group("name") if role else m.group("name2")
311+
312+
target_name = m.group("target_name")
313+
if target_name is not None:
314+
name += f" {target_name}"
311315
return name, role, m.end()
312316

313317
rest = []

numpydoc/tests/test_docscrape.py

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -110,6 +110,7 @@
110110
some, other, funcs
111111
otherfunc : relationship
112112
:py:meth:`spyder.widgets.mixins.GetHelpMixin.show_object_info`
113+
:py:meth:`int.bit_length <int.bit_length>`
113114
114115
Examples
115116
--------
@@ -451,6 +452,8 @@ def test_str(doc):
451452
relationship
452453
:py:meth:`spyder.widgets.mixins.GetHelpMixin.show_object_info`
453454
..
455+
:py:meth:`int.bit_length <int.bit_length>`
456+
..
454457
455458
Notes
456459
-----
@@ -642,6 +645,8 @@ def test_sphinx_str():
642645
relationship
643646
:py:meth:`spyder.widgets.mixins.GetHelpMixin.show_object_info`
644647
..
648+
:py:meth:`int.bit_length <int.bit_length>`
649+
..
645650
646651
.. rubric:: Notes
647652

0 commit comments

Comments
 (0)