summary refs log tree commit diff stats
path: root/tests/test-qmp-input-strict.c
diff options
context:
space:
mode:
authorPeter Maydell <peter.maydell@linaro.org>2014-03-12 10:47:07 +0000
committerPeter Maydell <peter.maydell@linaro.org>2014-03-12 10:47:07 +0000
commit613c12ec28573b10cae0cd91139ba69b964f347c (patch)
treeb66907dde9f7aa0bf57503fea2be092b43d26e56 /tests/test-qmp-input-strict.c
parentbe813ef02d18ba58e1ff32f1706bcacb88f1f764 (diff)
parent2a7a1a56d1e30de07cf7d7636a35bf7706b9500e (diff)
downloadfocaccia-qemu-613c12ec28573b10cae0cd91139ba69b964f347c.tar.gz
focaccia-qemu-613c12ec28573b10cae0cd91139ba69b964f347c.zip
Merge remote-tracking branch 'remotes/qmp-unstable/queue/qmp' into staging
* remotes/qmp-unstable/queue/qmp:
  tests: test-qmp-commands: Fix double free
  qapi script: do not add "_" for every capitalized char in enum
  qapi script: do not allow string discriminator
  qapi: convert BlockdevOptions to use enum discriminator
  qapi script: support enum type as discriminator in union
  qapi script: use same function to generate enum string
  qapi script: code move for generate_enum_name()
  qapi script: check correctness of union
  qapi script: remember line number in schema parsing
  qapi script: add check for duplicated key
  qapi script: remember explicitly defined enum values

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'tests/test-qmp-input-strict.c')
-rw-r--r--tests/test-qmp-input-strict.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/tests/test-qmp-input-strict.c b/tests/test-qmp-input-strict.c
index 64d72f6f05..38b5e95f68 100644
--- a/tests/test-qmp-input-strict.c
+++ b/tests/test-qmp-input-strict.c
@@ -146,7 +146,10 @@ static void test_validate_union_flat(TestInputVisitorData *data,
     Visitor *v;
     Error *errp = NULL;
 
-    v = validate_test_init(data, "{ 'string': 'a', 'boolean': true }");
+    v = validate_test_init(data,
+                           "{ 'enum1': 'value1', "
+                           "'string': 'str', "
+                           "'boolean': true }");
     /* TODO when generator bug is fixed, add 'integer': 41 */
 
     visit_type_UserDefFlatUnion(v, &tmp, NULL, &errp);