From nobody Sun Feb 8 23:27:16 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 170.10.129.124 as permitted sender) client-ip=170.10.129.124; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-124.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 170.10.129.124 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1644422646; cv=none; d=zohomail.com; s=zohoarc; b=icX5iLjF26A/jxxRwpsXv6zlAGujH634L0esrkORQnJEn+aaI9SB9FrasXWUBMabZ+ifjfOtDArtn2CDtRq7jyPlUaEB0y2NnlRf77daozOIahpJX2t93nMjjAHcAWFdV8WIcfnsOeG7Ei0FDbJyIwKYuGV0lsqc6VwpQor+sqE= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1644422646; h=Content-Type:Content-Transfer-Encoding:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=2sxakj9J8qdtMkfUsTX/HSZsmqEgG8NVMSyZta1e4G8=; b=LTes8qd5C/VdBx/KJcThY1Q6ITAO6IyUbqHx+PXZDydERHK2qpl5Jm9KhIm+sVvXaAavU6XTkSKmOBiIsFJ01tLlqpeuQx5snj44ykIKjbfHIAY1vvRnHIjRzUcCrTcxi69Lx2E2IJsVUdZtKVr8wAfbQ3zbJDXP75xqx2Liugo= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 170.10.129.124 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.129.124]) by mx.zohomail.com with SMTPS id 1644422646083328.21050157254047; Wed, 9 Feb 2022 08:04:06 -0800 (PST) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-664-NGkE_RFcOb-V8LnSZ9G5zQ-1; Wed, 09 Feb 2022 11:03:40 -0500 Received: from smtp.corp.redhat.com (int-mx05.intmail.prod.int.phx2.redhat.com [10.5.11.15]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 83390193F570; Wed, 9 Feb 2022 16:03:05 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.20]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 63AE670F60; Wed, 9 Feb 2022 16:03:05 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 092E41803390; Wed, 9 Feb 2022 16:03:05 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 219G2oIm012364 for ; Wed, 9 Feb 2022 11:02:50 -0500 Received: by smtp.corp.redhat.com (Postfix) id 982697DE42; Wed, 9 Feb 2022 16:02:50 +0000 (UTC) Received: from speedmetal.redhat.com (unknown [10.40.208.41]) by smtp.corp.redhat.com (Postfix) with ESMTP id F20DE7DE40 for ; Wed, 9 Feb 2022 16:02:49 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1644422644; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=2sxakj9J8qdtMkfUsTX/HSZsmqEgG8NVMSyZta1e4G8=; b=ErVvzSVePXrFORxKtR+XS2njG6wiEq8afOEHQiUbqclu0u9Mjs7+vsx37VC6SiUaS0eftg KyyYAl+tO6MhTl1aBlGrYCH6xqulPnsDT7oiGOmVsAF4mIfgk2OlKd9Uqhp0Oyknkbl4Xt AuNIAr96V4yvn1kPBHIiRUQD8bzHyRo= X-MC-Unique: NGkE_RFcOb-V8LnSZ9G5zQ-1 From: Peter Krempa To: libvir-list@redhat.com Subject: [PATCH 16/27] qemumonitorjsontest: chardev: Remove need to allow unused commands Date: Wed, 9 Feb 2022 17:02:08 +0100 Message-Id: <536f061d2266220525f192bb7ff1215036db437c.1644422239.git.pkrempa@redhat.com> In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 X-loop: libvir-list@redhat.com X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.15 Authentication-Results: relay.mimecast.com; auth=pass smtp.auth=CUSA124A263 smtp.mailfrom=libvir-list-bounces@redhat.com X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) X-ZM-MESSAGEID: 1644422647928100001 Content-Type: text/plain; charset="utf-8" Don't add the command to the test monitor when we don't expect to invoke it rather than bypassing the test monitor. Signed-off-by: Peter Krempa Reviewed-by: J=C3=A1n Tomko --- tests/qemumonitorjsontest.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/tests/qemumonitorjsontest.c b/tests/qemumonitorjsontest.c index 7987182a82..b7937a6046 100644 --- a/tests/qemumonitorjsontest.c +++ b/tests/qemumonitorjsontest.c @@ -659,9 +659,8 @@ qemuMonitorJSONTestAttachOneChardev(virDomainXMLOption = *xmlopt, fulllabel =3D g_strdup_printf("qemuMonitorJSONTestAttachChardev(%s)", = label); - qemuMonitorTestAllowUnusedCommands(test); - - if (qemuMonitorTestAddItemExpect(test, "chardev-add", + if (expectargs && + qemuMonitorTestAddItemExpect(test, "chardev-add", expectargs, true, jsonreply) < 0) return -1; @@ -784,10 +783,10 @@ qemuMonitorJSONTestAttachChardev(virDomainXMLOption *= xmlopt, "data':{'type':'vdagent'}}}"); chr =3D (virDomainChrSourceDef) { .type =3D VIR_DOMAIN_CHR_TYPE_PIPE }; - CHECK("pipe", true, ""); + CHECK("pipe", true, NULL); chr =3D (virDomainChrSourceDef) { .type =3D VIR_DOMAIN_CHR_TYPE_STDIO = }; - CHECK("stdio", true, ""); + CHECK("stdio", true, NULL); #undef CHECK return ret; --=20 2.34.1