Eric Blake <ebl...@redhat.com> writes: > Demonstrate that the qapi generator silently parses confusing > types, which may cause other errors later on. Later patches > will update the expected results as the generator is made stricter. > > * tests/qapi-schema/data-array-empty.*: New files. > * tests/qapi-schema/data-array-unknown.*: Likewise. > * tests/qapi-schema/data-unknown.*: Likewise. > * tests/qapi-schema/data-int.*: Likewise. > * tests/qapi-schema/returns-unknown.*: Likewise. > * tests/qapi-schema/returns-int.*: Likewise. > * tests/qapi-schema/returns-array-bad.*: Likewise. > * tests/Makefile (check-qapi-schema-y): Run them. > > Signed-off-by: Eric Blake <ebl...@redhat.com> [...] > diff --git a/tests/qapi-schema/returns-array-bad.err > b/tests/qapi-schema/returns-array-bad.err > new file mode 100644 > index 0000000..e69de29 > diff --git a/tests/qapi-schema/returns-array-bad.exit > b/tests/qapi-schema/returns-array-bad.exit > new file mode 100644 > index 0000000..573541a > --- /dev/null > +++ b/tests/qapi-schema/returns-array-bad.exit > @@ -0,0 +1 @@ > +0 > diff --git a/tests/qapi-schema/returns-array-bad.json > b/tests/qapi-schema/returns-array-bad.json > new file mode 100644 > index 0000000..76bf6df > --- /dev/null > +++ b/tests/qapi-schema/returns-array-bad.json > @@ -0,0 +1 @@ > +{ 'command': 'oops', 'data': [ 'str', 'str' ] }
The file name suggests you want to test 'returns' rather than 'data' here. [...]