diff options
Diffstat (limited to 'tests')
| -rw-r--r-- | tests/qapi-schema/doc-bad-indent.err | 2 | ||||
| -rw-r--r-- | tests/qapi-schema/doc-bad-indent.json | 3 | ||||
| -rw-r--r-- | tests/qapi-schema/doc-good.json | 20 | ||||
| -rw-r--r-- | tests/qapi-schema/doc-good.out | 19 |
4 files changed, 28 insertions, 16 deletions
diff --git a/tests/qapi-schema/doc-bad-indent.err b/tests/qapi-schema/doc-bad-indent.err index 67844539bd..3c9699a8e0 100644 --- a/tests/qapi-schema/doc-bad-indent.err +++ b/tests/qapi-schema/doc-bad-indent.err @@ -1 +1 @@ -doc-bad-indent.json:6:1: unexpected de-indent (expected at least 4 spaces) +doc-bad-indent.json:7:1: unexpected de-indent (expected at least 2 spaces) diff --git a/tests/qapi-schema/doc-bad-indent.json b/tests/qapi-schema/doc-bad-indent.json index edde8f21dc..3f22a27717 100644 --- a/tests/qapi-schema/doc-bad-indent.json +++ b/tests/qapi-schema/doc-bad-indent.json @@ -3,6 +3,7 @@ ## # @foo: # @a: line one -# line two is wrongly indented +# line two +# line three is wrongly indented ## { 'command': 'foo', 'data': { 'a': 'int' } } diff --git a/tests/qapi-schema/doc-good.json b/tests/qapi-schema/doc-good.json index 74745fb405..354dfdf461 100644 --- a/tests/qapi-schema/doc-good.json +++ b/tests/qapi-schema/doc-good.json @@ -54,7 +54,7 @@ ## # @Enum: # -# @one: The _one_ {and only} +# @one: The _one_ {and only}, description on the same line # # Features: # @enum-feat: Also _one_ {and only} @@ -73,7 +73,8 @@ # @Base: # # @base1: -# the first member +# description starts on a new line, +# not indented ## { 'struct': 'Base', 'data': { 'base1': 'Enum' }, 'if': { 'all': ['IFALL1', 'IFALL2'] } } @@ -83,7 +84,9 @@ # # A paragraph # -# Another paragraph (but no @var: line) +# Another paragraph +# +# @var1 is undocumented # # Features: # @variant1-feat: a feature @@ -118,7 +121,8 @@ ## # @Alternate: # -# @i: an integer +# @i: description starts on the same line +# remainder indented the same # @b is undocumented # # Features: @@ -136,10 +140,12 @@ ## # @cmd: # -# @arg1: the first argument +# @arg1: +# description starts on a new line, +# indented # -# @arg2: the second -# argument +# @arg2: description starts on the same line +# remainder indented differently # # Features: # @cmd-feat1: a feature diff --git a/tests/qapi-schema/doc-good.out b/tests/qapi-schema/doc-good.out index 9dd65b9d92..24d9ea954d 100644 --- a/tests/qapi-schema/doc-good.out +++ b/tests/qapi-schema/doc-good.out @@ -104,7 +104,7 @@ doc symbol=Enum body= arg=one -The _one_ {and only} +The _one_ {and only}, description on the same line arg=two feature=enum-feat @@ -117,12 +117,15 @@ doc symbol=Base body= arg=base1 -the first member +description starts on a new line, +not indented doc symbol=Variant1 body= A paragraph -Another paragraph (but no @var: line) +Another paragraph + +@var1 is undocumented arg=var1 feature=variant1-feat @@ -141,7 +144,8 @@ doc symbol=Alternate body= arg=i -an integer +description starts on the same line +remainder indented the same @b is undocumented arg=b @@ -154,10 +158,11 @@ doc symbol=cmd body= arg=arg1 -the first argument +description starts on a new line, +indented arg=arg2 -the second -argument +description starts on the same line +remainder indented differently arg=arg3 feature=cmd-feat1 |