From nobody Thu Apr 25 20:14:14 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 170.10.133.124 as permitted sender) client-ip=170.10.133.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.133.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=1641994964; cv=none; d=zohomail.com; s=zohoarc; b=eh/KcRJt0MuqaJh4NBfzn4LbOfg/kehe4XzVf1ztj4k4f7BuKEjQhYzFbWNhnV5h1+ih46O7LUFcgJ664RbJyDsHtA5PP4RR1xSaWlnMCIE45huxtQidxvaC2Wy4PZ/GKv9M7CPih+p17adawPMPNloR85ZQ5qSZBSUdb8BMqJY= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1641994964; h=Content-Type:Content-Transfer-Encoding:Date:From:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Sender:Subject:To; bh=SokebCBDI+7vsFKfH0H7kgXDWyjRmP8TLq+GQzYJWWI=; b=nmKMpB2y3Ny4l0ofK94kCVbfUfeMK6BCFYxMWdPe4DIrxsnb4i33r9eoUWf4EZ0VvyXHjQM0NmRfGAbwHkoLxk2HIIDOJL+gHEKISzVt8Fo26UJJrAiAezhCw/Yi2QJlyBqae5U/E5/QI1TfppQsTqu0bkbio1SUo65udNzExsY= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 170.10.133.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.133.124]) by mx.zohomail.com with SMTPS id 164199496407856.37638171559411; Wed, 12 Jan 2022 05:42:44 -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-394-Sj2JkEltMnCmDo-mWXRMyA-1; Wed, 12 Jan 2022 08:42:41 -0500 Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.phx2.redhat.com [10.5.11.23]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 23D9C18B613A; Wed, 12 Jan 2022 13:42:36 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 507CB23797; Wed, 12 Jan 2022 13:42:35 +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 A93D74BB7B; Wed, 12 Jan 2022 13:42:33 +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 20CDgWEE015534 for ; Wed, 12 Jan 2022 08:42:32 -0500 Received: by smtp.corp.redhat.com (Postfix) id C67597D3DF; Wed, 12 Jan 2022 13:42:32 +0000 (UTC) Received: from maggie.redhat.com (unknown [10.43.2.56]) by smtp.corp.redhat.com (Postfix) with ESMTP id 4C45B7D3D5 for ; Wed, 12 Jan 2022 13:42:21 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1641994963; 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:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=SokebCBDI+7vsFKfH0H7kgXDWyjRmP8TLq+GQzYJWWI=; b=agtXSB/EHGVlK9wIlXWRe6+WueZtEdrRBz8NMZUnJUDaErheW9laXhl6IdUMpY/mlrfiQH WhDGtIQ8lkrw1I3+G3loIMwR1hxjnSg4bi7eFoHs7fHqYhN01LuQJe51m7LF3RwqIApSK0 px05tavK7YUI/ICrrrtzcNO+ewVmvuI= X-MC-Unique: Sj2JkEltMnCmDo-mWXRMyA-1 From: Michal Privoznik To: libvir-list@redhat.com Subject: [PATCH] tests: Report expected monitor command for simulated commands Date: Wed, 12 Jan 2022 14:42:16 +0100 Message-Id: <4e663c84f32ed73c5c05755c9a2a4ace8262d1e7.1641994936.git.mprivozn@redhat.com> 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.84 on 10.5.11.23 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: 1641994965482100004 Content-Type: text/plain; charset="utf-8" There are two tests currently that simulate QMP talk: qemucapabilitiestest and qemuhotplugtest. In both cases they check whether currently executed command is the one for which reply was provided. If not an error message is reported. However, the error message contains only the actual command and not the expected one. This makes it harder to navigate through .replies files. Signed-off-by: Michal Privoznik Reviewed-by: J=C3=A1n Tomko --- tests/qemumonitortestutils.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/tests/qemumonitortestutils.c b/tests/qemumonitortestutils.c index f7a0a37685..073ae5d73a 100644 --- a/tests/qemumonitortestutils.c +++ b/tests/qemumonitortestutils.c @@ -648,7 +648,8 @@ qemuMonitorTestProcessCommandVerbatim(qemuMonitorTest *= test, ret =3D qemuMonitorTestAddResponse(test, data->response); } else { if (data->cmderr) { - qemuMonitorTestError("%s: %s", data->cmderr, cmdstr); + qemuMonitorTestError("%s: %s expected %s", + data->cmderr, cmdstr, data->command_name); } else { qemuMonitorTestErrorInvalidCommand(data->command_name, cmdstr); } --=20 2.34.1