diff options
| author | Eric Blake | 2015-10-13 06:22:24 +0200 |
|---|---|---|
| committer | Markus Armbruster | 2015-10-15 08:39:07 +0200 |
| commit | 625b251c69d983959efaeadeee12405b1a66d331 (patch) | |
| tree | c6f7272da89e6f97533a421ecbbf962bd17cc769 /tests/qapi-schema/qapi-schema-test.json | |
| parent | qapi: Drop redundant alternate-good test (diff) | |
| download | qemu-625b251c69d983959efaeadeee12405b1a66d331.tar.gz qemu-625b251c69d983959efaeadeee12405b1a66d331.tar.xz qemu-625b251c69d983959efaeadeee12405b1a66d331.zip | |
qapi: Move empty-enum to compile-time test
Rather than just asserting that we can parse an empty enum,
let's also make sure we can compile it, by including it in
qapi-schema-test.
Signed-off-by: Eric Blake <eblake@redhat.com>
Message-Id: <1444710158-8723-5-git-send-email-eblake@redhat.com>
Signed-off-by: Markus Armbruster <armbru@redhat.com>
Diffstat (limited to 'tests/qapi-schema/qapi-schema-test.json')
| -rw-r--r-- | tests/qapi-schema/qapi-schema-test.json | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/tests/qapi-schema/qapi-schema-test.json b/tests/qapi-schema/qapi-schema-test.json index abe59fd137..c8cd2ddb92 100644 --- a/tests/qapi-schema/qapi-schema-test.json +++ b/tests/qapi-schema/qapi-schema-test.json @@ -1,11 +1,17 @@ # *-*- Mode: Python -*-* +# This file is a stress test of supported qapi constructs that must +# parse and compile correctly. + # for testing enums { 'enum': 'EnumOne', 'data': [ 'value1', 'value2', 'value3' ] } { 'struct': 'NestedEnumsOne', 'data': { 'enum1': 'EnumOne', '*enum2': 'EnumOne', 'enum3': 'EnumOne', '*enum4': 'EnumOne' } } +# An empty enum, although unusual, is currently acceptable +{ 'enum': 'MyEnum', 'data': [ ] } + # for testing override of default naming heuristic { 'enum': 'QEnumTwo', 'prefix': 'QENUM_TWO', |
