tests/qapi-schema: Wean off UserDefListUnion

Command boxed-union uses simple union UserDefListUnion to cover
unions.  Use UserDefFlatUnion instead.

Signed-off-by: Markus Armbruster <armbru@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
Message-Id: <20210917143134.412106-16-armbru@redhat.com>
This commit is contained in:
Markus Armbruster 2021-09-17 16:31:26 +02:00
parent 16821fc85b
commit 1e65e16ca3
3 changed files with 3 additions and 3 deletions

View File

@ -175,7 +175,7 @@
'returns': 'int' }
{ 'command': 'guest-sync', 'data': { 'arg': 'any' }, 'returns': 'any' }
{ 'command': 'boxed-struct', 'boxed': true, 'data': 'UserDefZero' }
{ 'command': 'boxed-union', 'data': 'UserDefListUnion', 'boxed': true }
{ 'command': 'boxed-union', 'data': 'UserDefFlatUnion', 'boxed': true }
{ 'command': 'boxed-empty', 'boxed': true, 'data': 'Empty1' }
# Smoke test on out-of-band and allow-preconfig-test

View File

@ -232,7 +232,7 @@ command guest-sync q_obj_guest-sync-arg -> any
gen=True success_response=True boxed=False oob=False preconfig=False
command boxed-struct UserDefZero -> None
gen=True success_response=True boxed=True oob=False preconfig=False
command boxed-union UserDefListUnion -> None
command boxed-union UserDefFlatUnion -> None
gen=True success_response=True boxed=True oob=False preconfig=False
command boxed-empty Empty1 -> None
gen=True success_response=True boxed=True oob=False preconfig=False

View File

@ -119,7 +119,7 @@ void qmp_boxed_struct(UserDefZero *arg, Error **errp)
{
}
void qmp_boxed_union(UserDefListUnion *arg, Error **errp)
void qmp_boxed_union(UserDefFlatUnion *arg, Error **errp)
{
}