From nobody Mon Feb 9 10:30:29 2026 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=1634542722; cv=none; d=zohomail.com; s=zohoarc; b=MoOh57XphomaZHlzhfw09mXGfZ4pbc3FN3XFt62FR0HBvdEYoOOjL7cCi5Db2MfTQiRi/C+P7cKjUFu45kCpF/wqffZgzbj4uZWekwHarGiGBt+d4ARQOphpQBemzYTuhhyTW+aQ6S7e3zB7QjMh8dezjNPKnOs1TrxM0fP9ep4= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1634542722; 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=fw/ujdbYwxTEG2mmc+W3QIJnXHJ6xMERE1PO1kKfJeI=; b=VKADOmwFVsdpiTuV/67sfZhYOHpCPmuzwn+NGLcfrmzAtAyUMgbpbu1g2+SmVYAk8mJoXoG82N1tsGVrgfj8/EbuQ+Y3vP3Gx1IhHOUkJKueAKlMM1Kn5HnDFsgbYgX27n2tstKxwe6vj6z4ESRLnRxfSST4hjVaQDXYWaBlQho= 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 1634542722022626.9036141893624; Mon, 18 Oct 2021 00:38:42 -0700 (PDT) Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-118-cumH-4QSMp-2hCgWx5OBCg-1; Mon, 18 Oct 2021 03:38:37 -0400 Received: from smtp.corp.redhat.com (int-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.12]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 2FB3D800685; Mon, 18 Oct 2021 07:38:30 +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 0C75F60C82; Mon, 18 Oct 2021 07:38:30 +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 8E3AE4EA2A; Mon, 18 Oct 2021 07:38:29 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.13]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 19I7bUs0016749 for ; Mon, 18 Oct 2021 03:37:31 -0400 Received: by smtp.corp.redhat.com (Postfix) id D65F17086D; Mon, 18 Oct 2021 07:37:30 +0000 (UTC) Received: from speedmetal.lan (unknown [10.40.208.20]) by smtp.corp.redhat.com (Postfix) with ESMTP id 2F95E5BB12 for ; Mon, 18 Oct 2021 07:37:27 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1634542721; 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=fw/ujdbYwxTEG2mmc+W3QIJnXHJ6xMERE1PO1kKfJeI=; b=HiZO0POVyIxjK2k8jRuzqmtZmn6VKs0kV+kgdWMcVC2q6WKv3ml1dFpghUMRspXHComQU6 a4RVEoIc9ryI4i0HDGwBjV6k+KLko1YBZVzM/xc5ThSQm1fUHC5cRAi81xpNq5ts7AZCRA ND15WJX12ByxR5Ts0qPeuYOiN6GR/JE= X-MC-Unique: cumH-4QSMp-2hCgWx5OBCg-1 From: Peter Krempa To: libvir-list@redhat.com Subject: [PATCH 3/6] qemuMonitorTestProcessCommandDefaultValidate: Partially validate 'device_add' Date: Mon, 18 Oct 2021 09:37:09 +0200 Message-Id: <0eda90c402c5c8d26e06c37d0e95cce1a5bdef1b.1634542402.git.pkrempa@redhat.com> In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.13 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.12 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: 1634542722868100001 Content-Type: text/plain; charset="utf-8" Use the 'allowIncomplete' argument of testQEMUSchemaValidateCommand to validate at least properties which are already described by the schema. Signed-off-by: Peter Krempa --- tests/qemumonitortestutils.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/tests/qemumonitortestutils.c b/tests/qemumonitortestutils.c index f5eb77d190..35a1bce071 100644 --- a/tests/qemumonitortestutils.c +++ b/tests/qemumonitortestutils.c @@ -524,6 +524,7 @@ qemuMonitorTestProcessCommandDefaultValidate(qemuMonito= rTest *test, virJSONValue *args) { g_auto(virBuffer) debug =3D VIR_BUFFER_INITIALIZER; + bool allowIncomplete =3D false; if (!test->qapischema) return 0; @@ -535,14 +536,14 @@ qemuMonitorTestProcessCommandDefaultValidate(qemuMoni= torTest *test, return -1; } - /* 'device_add' needs to be skipped as it does not have fully defined = schema */ + /* The schema of 'device_add' is incomplete so we relax the validator = */ if (STREQ(cmdname, "device_add")) - return 0; + allowIncomplete =3D true; if (testQEMUSchemaValidateCommand(cmdname, args, test->qapischema, test->skipValidationDeprecated, test->skipValidationRemoved, - false, + allowIncomplete, &debug) < 0) { if (virTestGetDebug() =3D=3D 2) { g_autofree char *argstr =3D NULL; --=20 2.31.1