[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[PULL 03/19] tests/qapi-schema: Cover alternate documentation comments
From: |
Markus Armbruster |
Subject: |
[PULL 03/19] tests/qapi-schema: Cover alternate documentation comments |
Date: |
Tue, 29 Oct 2019 11:22:12 +0100 |
Signed-off-by: Markus Armbruster <address@hidden>
Message-Id: <address@hidden>
---
tests/qapi-schema/doc-good.texi | 17 +++++++++++++++++
tests/qapi-schema/doc-good.json | 8 ++++++++
tests/qapi-schema/doc-good.out | 12 ++++++++++++
3 files changed, 37 insertions(+)
diff --git a/tests/qapi-schema/doc-good.texi b/tests/qapi-schema/doc-good.texi
index d6ecdac94f..98aa78e1fb 100644
--- a/tests/qapi-schema/doc-good.texi
+++ b/tests/qapi-schema/doc-good.texi
@@ -170,6 +170,23 @@ One of @t{"one"}, @t{"two"}
@end deftp
+
+@deftp {Alternate} Alternate
+
+
+
+@b{Members:}
+@table @asis
+@item @code{i: int}
+an integer
+@code{b} is undocumented
+@item @code{b: boolean}
+Not documented
+@end table
+
+@end deftp
+
+
@subsection Another subsection
diff --git a/tests/qapi-schema/doc-good.json b/tests/qapi-schema/doc-good.json
index 1ae6c3a9da..df50a877e3 100644
--- a/tests/qapi-schema/doc-good.json
+++ b/tests/qapi-schema/doc-good.json
@@ -98,6 +98,14 @@
{ 'union': 'SugaredUnion',
'data': { 'one': 'Variant1', 'two': { 'type': 'Variant2', 'if': 'IFTWO' } } }
+##
+# @Alternate:
+# @i: an integer
+# @b is undocumented
+##
+{ 'alternate': 'Alternate',
+ 'data': { 'i': 'int', 'b': 'bool' } }
+
##
# == Another subsection
##
diff --git a/tests/qapi-schema/doc-good.out b/tests/qapi-schema/doc-good.out
index a8fc39d288..b0e99f2110 100644
--- a/tests/qapi-schema/doc-good.out
+++ b/tests/qapi-schema/doc-good.out
@@ -42,6 +42,10 @@ object SugaredUnion
case one: q_obj_Variant1-wrapper
case two: q_obj_Variant2-wrapper
if ['IFTWO']
+alternate Alternate
+ tag type
+ case i: int
+ case b: bool
object q_obj_cmd-arg
member arg1: int optional=False
member arg2: str optional=True
@@ -133,6 +137,14 @@ doc symbol=SugaredUnion
arg=type
+doc symbol=Alternate
+ body=
+
+ arg=i
+an integer
+@b is undocumented
+ arg=b
+
doc freeform
body=
== Another subsection
--
2.21.0
- [PULL 00/19] QAPI patches for 2019-10-29, Markus Armbruster, 2019/10/29
- [PULL 12/19] qapi: Simplify ._make_implicit_object_type(), Markus Armbruster, 2019/10/29
- [PULL 03/19] tests/qapi-schema: Cover alternate documentation comments,
Markus Armbruster <=
- [PULL 02/19] tests/qapi-schema: Demonstrate command and event doc comment bugs, Markus Armbruster, 2019/10/29
- [PULL 07/19] qapi: De-duplicate entity documentation generation code, Markus Armbruster, 2019/10/29
- [PULL 04/19] tests/qapi-schema: Fix feature documentation testing, Markus Armbruster, 2019/10/29
- [PULL 01/19] tests/qapi-schema: Demonstrate feature and enum doc comment bugs, Markus Armbruster, 2019/10/29
- [PULL 09/19] qapi: Fix enum doc comment checking, Markus Armbruster, 2019/10/29
- [PULL 13/19] qapi: Eliminate .check_doc() overrides, Markus Armbruster, 2019/10/29
- [PULL 05/19] qemu-doc: Belatedly document QMP command deprecation, Markus Armbruster, 2019/10/29
- [PULL 10/19] qapi: Clean up doc comment checking for implicit union base, Markus Armbruster, 2019/10/29
- [PULL 14/19] qapi: Fold normalize_if() into check_if(), Markus Armbruster, 2019/10/29
- [PULL 06/19] qapi: Implement boxed event argument documentation, Markus Armbruster, 2019/10/29