From nobody Mon Feb 9 16:54:11 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=1678813012; cv=none; d=zohomail.com; s=zohoarc; b=m1vgdskKxz9ldGjKA5evV34NCWovO6RabWZaDrNoMxlCG7a8iCRiTNHlOfsRxTf9Ybl9Xf0JOJfhOFu+VOfM/Uaehaz4Kw3d9br/zEkj8wC+1QYWG0LGUsCqhMRdu7wWMs56znnFkzmopFhooaAtmY0w788qEmXUPnDXvTGieiM= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1678813012; 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=q12b5Kn//29oZYXdjg6NTApOSUo56ndyIq0yg645TZ8=; b=Kyi1tArzpu8aRWxjd6Lfhu9ujPsJBcETvW+UTvq2Mh/k6YSdGG6+muuxQ1oF9W9wf2jCBzXEkSGd0G3SrIVZBOG3GSKuqzg6Ctt67SBDLVTNBriHVkh7beO0pdDpMNLqc2F90Jj3Y0jDj279quC/slzl54ljQTJXKFmnGdP+PUE= 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 1678813012020369.7428009194257; Tue, 14 Mar 2023 09:56:52 -0700 (PDT) Received: from mimecast-mx02.redhat.com (mx3-rdu2.redhat.com [66.187.233.73]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-578-hCs4JHyLPFWJdWqDEgk0_w-1; Tue, 14 Mar 2023 12:56:43 -0400 Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.rdu2.redhat.com [10.11.54.7]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 397203C11799; Tue, 14 Mar 2023 16:53:01 +0000 (UTC) Received: from mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (unknown [10.30.29.100]) by smtp.corp.redhat.com (Postfix) with ESMTP id 1D7421410F1B; Tue, 14 Mar 2023 16:53:01 +0000 (UTC) Received: from mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (localhost [IPv6:::1]) by mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (Postfix) with ESMTP id 014D91946A40; Tue, 14 Mar 2023 16:53:01 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.rdu2.redhat.com [10.11.54.6]) by mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (Postfix) with ESMTP id AC3DF19465B1 for ; Tue, 14 Mar 2023 16:52:33 +0000 (UTC) Received: by smtp.corp.redhat.com (Postfix) id DD7892166B2E; Tue, 14 Mar 2023 16:52:33 +0000 (UTC) Received: from localhost.localdomain (unknown [10.43.2.39]) by smtp.corp.redhat.com (Postfix) with ESMTP id 83CC42166B26 for ; Tue, 14 Mar 2023 16:52:33 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1678813011; 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=q12b5Kn//29oZYXdjg6NTApOSUo56ndyIq0yg645TZ8=; b=IcNBFMNwGtqWwN42MW8bS4e3dt1Tiquk5Bjp128Fn7ypLRHeVT4z/nXgpwej1llvO8Rzd4 bgPid8VlTjIzuYnhB4xUC2Q8EarZZbYrmfdOIsBAWvqG7cZHfatfdSQh+lTko0hApTjeQ5 BMxc1Xorfembhp9YP1adweyMiEbR6cE= X-MC-Unique: hCs4JHyLPFWJdWqDEgk0_w-1 X-Original-To: libvir-list@listman.corp.redhat.com From: Michal Privoznik To: libvir-list@redhat.com Subject: [PATCH v2 04/15] qemuxml2argvtest: Use virnuma mock Date: Tue, 14 Mar 2023 17:52:18 +0100 Message-Id: <6227d580a90349d801939fd00b22c3d1af0f16d2.1678812657.git.mprivozn@redhat.com> In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.1 on 10.11.54.6 X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.29 Precedence: list List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: libvir-list-bounces@redhat.com Sender: "libvir-list" X-Scanned-By: MIMEDefang 3.1 on 10.11.54.7 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: 1678813013491100001 Content-Type: text/plain; charset="utf-8"; x-default="true" While no part of cmd line building process currently depends on a host NUMA configuration, this will change soon. Use freshly changed virnumamock from qemuxml2argvtest and make the mock read NUMA data from vircaps2xmldata which seems to have the most rich NUMA configuration. This also means, we have to start building virnumamock unconditionally. But this is not a problem, since nothing inside of the mock relies on Linux specificity. The whole mock is merely just reading files and parsing them. Signed-off-by: Michal Privoznik --- tests/meson.build | 2 +- tests/qemuxml2argvtest.c | 5 ++++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/tests/meson.build b/tests/meson.build index 15b049c6ac..0fd3bc62cf 100644 --- a/tests/meson.build +++ b/tests/meson.build @@ -84,6 +84,7 @@ mock_libs =3D [ { 'name': 'virnetdaemonmock' }, { 'name': 'virnetdevmock' }, { 'name': 'virnetserverclientmock' }, + { 'name': 'virnumamock' }, { 'name': 'virpcimock' }, { 'name': 'virportallocatormock' }, { 'name': 'virprocessmock' }, @@ -94,7 +95,6 @@ if host_machine.system() =3D=3D 'linux' mock_libs +=3D [ { 'name': 'virfilemock' }, { 'name': 'virnetdevbandwidthmock' }, - { 'name': 'virnumamock' }, { 'name': 'virtestmock' }, { 'name': 'virusbmock' }, ] diff --git a/tests/qemuxml2argvtest.c b/tests/qemuxml2argvtest.c index c879fa90e0..efecb7c89d 100644 --- a/tests/qemuxml2argvtest.c +++ b/tests/qemuxml2argvtest.c @@ -830,6 +830,8 @@ mymain(void) linuxCaps =3D driver.caps; macOSCaps =3D testQemuCapsInitMacOS(); =20 + virFileWrapperAddPrefix("/sys/devices/system", + abs_srcdir "/vircaps2xmldata/linux-basic/syste= m"); virFileWrapperAddPrefix(SYSCONFDIR "/qemu/firmware", abs_srcdir "/qemufirmwaredata/etc/qemu/firmwar= e"); virFileWrapperAddPrefix(PREFIX "/share/qemu/firmware", @@ -2911,7 +2913,8 @@ VIR_TEST_MAIN_PRELOAD(mymain, VIR_TEST_MOCK("domaincaps"), VIR_TEST_MOCK("virrandom"), VIR_TEST_MOCK("qemucpu"), - VIR_TEST_MOCK("virpci")) + VIR_TEST_MOCK("virpci"), + VIR_TEST_MOCK("virnuma")) =20 #else =20 --=20 2.39.2