diff options
Diffstat (limited to 'qemu/tests/qapi-schema/union-base-no-discriminator.json')
-rw-r--r-- | qemu/tests/qapi-schema/union-base-no-discriminator.json | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/qemu/tests/qapi-schema/union-base-no-discriminator.json b/qemu/tests/qapi-schema/union-base-no-discriminator.json new file mode 100644 index 000000000..1409cf5c9 --- /dev/null +++ b/qemu/tests/qapi-schema/union-base-no-discriminator.json @@ -0,0 +1,14 @@ +# we reject simple unions with a base (or flat unions without discriminator) +{ 'struct': 'TestTypeA', + 'data': { 'string': 'str' } } + +{ 'struct': 'TestTypeB', + 'data': { 'integer': 'int' } } + +{ 'struct': 'Base', + 'data': { 'string': 'str' } } + +{ 'union': 'TestUnion', + 'base': 'Base', + 'data': { 'value1': 'TestTypeA', + 'value2': 'TestTypeB' } } |