diff options
author | Wenchao Xia <wenchaoqemu@gmail.com> | 2014-06-18 08:43:29 +0200 |
---|---|---|
committer | Luiz Capitulino <lcapitulino@redhat.com> | 2014-06-23 11:01:25 -0400 |
commit | f6dadb0242029e11640d9434efd39ec8211ea868 (patch) | |
tree | a3c74da908c61a8894aa4aad29547cad172625d6 /tests/qapi-schema/qapi-schema-test.json | |
parent | 21cd70dfc1a6dc90511bae55a460a3a55461339a (diff) |
test: add test cases for qapi event
These cases will verify whether the expected qdict is built.
Signed-off-by: Wenchao Xia <wenchaoqemu@gmail.com>
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
Reviewed-by: Eric Blake <eblake@redhat.com>
Signed-off-by: Luiz Capitulino <lcapitulino@redhat.com>
Diffstat (limited to 'tests/qapi-schema/qapi-schema-test.json')
-rw-r--r-- | tests/qapi-schema/qapi-schema-test.json | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/tests/qapi-schema/qapi-schema-test.json b/tests/qapi-schema/qapi-schema-test.json index 818c06dc75..ab4d3d96b6 100644 --- a/tests/qapi-schema/qapi-schema-test.json +++ b/tests/qapi-schema/qapi-schema-test.json @@ -89,3 +89,15 @@ '*u16' : [ 'uint16' ], '*i64x': 'int' , '*u64x': 'uint64' } } + +# testing event +{ 'type': 'EventStructOne', + 'data': { 'struct1': 'UserDefOne', 'string': 'str', '*enum2': 'EnumOne' } } + +{ 'event': 'EVENT_A' } +{ 'event': 'EVENT_B', + 'data': { } } +{ 'event': 'EVENT_C', + 'data': { '*a': 'int', '*b': 'UserDefOne', 'c': 'str' } } +{ 'event': 'EVENT_D', + 'data': { 'a' : 'EventStructOne', 'b' : 'str', '*c': 'str', '*enum3': 'EnumOne' } } |