From: Vladimír Vondruš
Date: Wed, 28 Aug 2019 16:07:27 +0000 (+0200)
Subject: documentation/python: test external summary for a submodule.
X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~cjwatson/git?a=commitdiff_plain;h=a7c83171ebc5ba45edd309512498b7b6aba3cd42;p=blog.git
documentation/python: test external summary for a submodule.
Fails. It's amazing how far can some bugs go unnoticed.
---
diff --git a/documentation/test_python/content/classes.html b/documentation/test_python/content/classes.html
index 293619c3..bf4f7223 100644
--- a/documentation/test_python/content/classes.html
+++ b/documentation/test_python/content/classes.html
@@ -25,6 +25,7 @@
module content This overwrites the docstring for content
.
- module docstring_summary This module retains summary from the docstring
+ - module submodule This submodule has an external summary.
- class Class This overwrites the docstring for
content.Class
.
- class ClassWithSummary This class has summary from the docstring
diff --git a/documentation/test_python/content/content.html b/documentation/test_python/content/content.html
index 9e0c0c92..3fb124db 100644
--- a/documentation/test_python/content/content.html
+++ b/documentation/test_python/content/content.html
@@ -45,6 +45,8 @@ tho.
- module docstring_summary
- This module retains summary from the docstring
+ - module submodule
+ - This submodule has an external summary.
diff --git a/documentation/test_python/content/content/__init__.py b/documentation/test_python/content/content/__init__.py
index 339c08c0..9850d0b7 100644
--- a/documentation/test_python/content/content/__init__.py
+++ b/documentation/test_python/content/content/__init__.py
@@ -1,7 +1,7 @@
"""Yes so this is module summary, not shown in the output"""
import enum
-from . import docstring_summary
+from . import docstring_summary, submodule
class Class:
"""And this class summary, not shown either"""
diff --git a/documentation/test_python/content/content/submodule.py b/documentation/test_python/content/content/submodule.py
new file mode 100644
index 00000000..54e2071f
--- /dev/null
+++ b/documentation/test_python/content/content/submodule.py
@@ -0,0 +1 @@
+# This module has an external summary
diff --git a/documentation/test_python/content/docs.rst b/documentation/test_python/content/docs.rst
index 2cac109d..76d3d884 100644
--- a/documentation/test_python/content/docs.rst
+++ b/documentation/test_python/content/docs.rst
@@ -13,6 +13,9 @@
And adds detailed docs.
+.. py:module:: content.submodule
+ :summary: This submodule has an external summary.
+
.. py:class:: content.Class
:summary: This overwrites the docstring for ``content.Class``.