Received: from eggs.gnu.org ([2001:4830:134:3::10]:58722) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1ezNNv-0007qm-Ix for qemu-devel@nongnu.org; Fri, 23 Mar 2018 10:09:37 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1ezNNs-0005MY-DG for qemu-devel@nongnu.org; Fri, 23 Mar 2018 10:09:35 -0400 Received: from mx3-rdu2.redhat.com ([66.187.233.73]:40730 helo=mx1.redhat.com) by eggs.gnu.org with esmtps (TLS1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.71) (envelope-from ) id 1ezNNs-0005MN-9H for qemu-devel@nongnu.org; Fri, 23 Mar 2018 10:09:32 -0400 From: Peter Xu Date: Fri, 23 Mar 2018 22:08:21 +0800 Message-Id: <20180323140821.28957-5-peterx@redhat.com> In-Reply-To: <20180323140821.28957-1-peterx@redhat.com> References: <20180323140821.28957-1-peterx@redhat.com> Subject: [Qemu-devel] [PATCH for-2.12 4/4] tests: partly revert "qmp: introduce QMPCapability" List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: Paolo Bonzini , "Daniel P . Berrange" , Christian Borntraeger , Fam Zheng , Kevin Wolf , Max Reitz , peterx@redhat.com, Eric Auger , Eric Blake , =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= , John Snow , Markus Armbruster , Peter Maydell Revert the tests in the patch 02130314d8 ("qmp: introduce QMPCapability", 2018-03-19) since we'll disable OOB for now. Signed-off-by: Peter Xu --- tests/qmp-test.c | 10 +--------- 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/tests/qmp-test.c b/tests/qmp-test.c index d1fa1cb217..558e83540c 100644 --- a/tests/qmp-test.c +++ b/tests/qmp-test.c @@ -80,8 +80,6 @@ static void test_qmp_protocol(void) QDict *resp, *q, *ret; QList *capabilities; QTestState *qts; - const QListEntry *entry; - QString *qstr; qts = qtest_init_without_qmp_handshake(common_args); @@ -91,13 +89,7 @@ static void test_qmp_protocol(void) g_assert(q); test_version(qdict_get(q, "version")); capabilities = qdict_get_qlist(q, "capabilities"); - g_assert(capabilities); - entry = qlist_first(capabilities); - g_assert(entry); - qstr = qobject_to(QString, entry->value); - g_assert(qstr); - g_assert_cmpstr(qstring_get_str(qstr), ==, "oob"); - QDECREF(resp); + g_assert(capabilities && qlist_empty(capabilities)); /* Test valid command before handshake */ resp = qtest_qmp(qts, "{ 'execute': 'query-version' }"); -- 2.14.3