summaryrefslogtreecommitdiffstats
path: root/rtemsqual/tests/test_content_sphinx.py
diff options
context:
space:
mode:
authorSebastian Huber <sebastian.huber@embedded-brains.de>2020-05-20 09:30:42 +0200
committerSebastian Huber <sebastian.huber@embedded-brains.de>2020-05-28 10:38:23 +0200
commit28ec35d299b2daa6a02d3d9e72f6ff53bbcb2513 (patch)
tree7da7c96d20b988fc44a6f27089869be25ec76ace /rtemsqual/tests/test_content_sphinx.py
parentcontent: Add Content.paste() (diff)
downloadrtems-central-28ec35d299b2daa6a02d3d9e72f6ff53bbcb2513.tar.bz2
content: Add list methods to SphinxContent
Diffstat (limited to 'rtemsqual/tests/test_content_sphinx.py')
-rw-r--r--rtemsqual/tests/test_content_sphinx.py22
1 files changed, 22 insertions, 0 deletions
diff --git a/rtemsqual/tests/test_content_sphinx.py b/rtemsqual/tests/test_content_sphinx.py
index 94d34fa4..8ce037b1 100644
--- a/rtemsqual/tests/test_content_sphinx.py
+++ b/rtemsqual/tests/test_content_sphinx.py
@@ -124,6 +124,28 @@ SectionEfGh
"""
+def test_list_item():
+ content = SphinxContent()
+ with content.list_item("ab cd"):
+ content.paste("ef gh")
+ with content.list_item("ij kl"):
+ content.add("mn op")
+ content.paste("qr st")
+ with content.list_item("uv"):
+ pass
+ content.add_list_item("wx")
+ assert str(content) == """* ab cd ef gh
+
+ * ij kl
+
+ mn op qr st
+
+* uv
+
+* wx
+"""
+
+
def test_append():
sc = SphinxContent()
sc.append("x")