From nobody Mon Feb 9 20:36:48 2026 Delivered-To: importer@patchew.org Received-SPF: none (zohomail.com: 8.43.85.245 is neither permitted nor denied by domain of lists.libvirt.org) client-ip=8.43.85.245; envelope-from=devel-bounces@lists.libvirt.org; helo=lists.libvirt.org; Authentication-Results: mx.zohomail.com; spf=none (zohomail.com: 8.43.85.245 is neither permitted nor denied by domain of lists.libvirt.org) smtp.mailfrom=devel-bounces@lists.libvirt.org; dmarc=fail(p=none dis=none) header.from=redhat.com Return-Path: Received: from lists.libvirt.org (lists.libvirt.org [8.43.85.245]) by mx.zohomail.com with SMTPS id 1711193761484764.6383121038501; Sat, 23 Mar 2024 04:36:01 -0700 (PDT) Received: by lists.libvirt.org (Postfix, from userid 996) id 3289E1E44; Sat, 23 Mar 2024 07:35:57 -0400 (EDT) Received: from lists.libvirt.org (localhost [IPv6:::1]) by lists.libvirt.org (Postfix) with ESMTP id 4BCDA2130; Sat, 23 Mar 2024 07:33:09 -0400 (EDT) Received: by lists.libvirt.org (Postfix, from userid 996) id A4EBE1DE2; Sat, 23 Mar 2024 07:33:01 -0400 (EDT) Received: from mx1.osci.io (polly.osci.io [8.43.85.229]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by lists.libvirt.org (Postfix) with ESMTPS id A2CEC1AAC for ; Sat, 23 Mar 2024 07:32:51 -0400 (EDT) Received: by mx1.osci.io (Postfix, from userid 994) id D11E0223F6; Fri, 22 Mar 2024 13:56:51 -0400 (EDT) Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (3072 bits) server-digest SHA256) (No client certificate requested) by mx1.osci.io (Postfix) with ESMTPS id 61685223F4 for ; Fri, 22 Mar 2024 13:56:51 -0400 (EDT) Received: from mimecast-mx02.redhat.com (mx-ext.redhat.com [66.187.233.73]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.3, cipher=TLS_AES_256_GCM_SHA384) id us-mta-214-fWOsU8ocNxCxWAtVcyR0Uw-1; Fri, 22 Mar 2024 13:56:49 -0400 Received: from smtp.corp.redhat.com (int-mx10.intmail.prod.int.rdu2.redhat.com [10.11.54.10]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id E4D5038012DD for ; Fri, 22 Mar 2024 17:56:48 +0000 (UTC) Received: from speedmetal.lan (unknown [10.45.242.6]) by smtp.corp.redhat.com (Postfix) with ESMTP id 5BFB1492BD0 for ; Fri, 22 Mar 2024 17:56:48 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on lists.libvirt.org X-Spam-Level: X-Spam-Status: No, score=-0.7 required=5.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE autolearn=unavailable autolearn_force=no version=3.4.4 X-MC-Unique: fWOsU8ocNxCxWAtVcyR0Uw-1 From: Peter Krempa To: devel@lists.libvirt.org Subject: [PATCH 31/35] virshtest: Adapt 'libvirtd-pool' Date: Fri, 22 Mar 2024 18:56:09 +0100 Message-ID: <8c76b013b71010a3128d6a2dd9871d8395d16aaf.1711129973.git.pkrempa@redhat.com> In-Reply-To: References: MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.4.1 on 10.11.54.10 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Message-ID-Hash: 3TQCENENX5NHSKELQRAYVNN7PXAU46DF X-Message-ID-Hash: 3TQCENENX5NHSKELQRAYVNN7PXAU46DF X-MailFrom: SRS0=Xa5W=K4=redhat.com=pkrempa@osci.io X-Mailman-Rule-Misses: dmarc-mitigation; no-senders; approved; emergency; loop; banned-address; member-moderation; header-match-config-1; header-match-config-2; header-match-config-3; header-match-devel.lists.libvirt.org-0; nonmember-moderation; administrivia; implicit-dest; max-recipients; max-size; news-moderation; no-subject; suspicious-header X-Mailman-Version: 3.2.2 Precedence: list List-Id: Development discussions about the libvirt library & tools Archived-At: List-Archive: List-Help: List-Post: List-Subscribe: List-Unsubscribe: Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-ZM-MESSAGEID: 1711193762142100001 The test case is a fairly simple invocation of pool-create-as which can be done easily from 'virshtest'. Signed-off-by: Peter Krempa --- tests/libvirtd-pool | 38 -------------------------- tests/meson.build | 1 - tests/virshtest.c | 3 ++ tests/virshtestdata/pool-define-as.out | 12 ++++++++ 4 files changed, 15 insertions(+), 39 deletions(-) delete mode 100755 tests/libvirtd-pool create mode 100644 tests/virshtestdata/pool-define-as.out diff --git a/tests/libvirtd-pool b/tests/libvirtd-pool deleted file mode 100755 index 4be65c68fe..0000000000 --- a/tests/libvirtd-pool +++ /dev/null @@ -1,38 +0,0 @@ -#!/bin/sh -# Get coverage of virsh pool-define-as XML formatting - -. "$(dirname $0)/test-lib.sh" - -if test "$VERBOSE" =3D yes; then - set -x - $abs_top_builddir/tools/virsh --version -fi - -fail=3D0 - -pwd=3D$(pwd) || fail=3D1 - -$abs_top_builddir/tools/virsh --connect test:///default \ - pool-define-as --print-xml \ - P dir src-host /src/path /src/dev S /target-path \ - 1>out 2>&1 - -cat < pool-list-exp - - P - - - - - S - - - /target-path - - - -EOF - -compare pool-list-exp out || fail=3D1 - -exit $fail diff --git a/tests/meson.build b/tests/meson.build index c760fe68d9..68f7635df9 100644 --- a/tests/meson.build +++ b/tests/meson.build @@ -689,7 +689,6 @@ test_scripts =3D [] if conf.has('WITH_LIBVIRTD') test_scripts +=3D [ 'libvirtd-fail', - 'libvirtd-pool', 'virsh-auth', 'virsh-self-test', 'virsh-uriprecedence', diff --git a/tests/virshtest.c b/tests/virshtest.c index f520ff9fc9..4e11a1cb04 100644 --- a/tests/virshtest.c +++ b/tests/virshtest.c @@ -304,6 +304,9 @@ mymain(void) DO_TEST_FULL("domain-id-overflow", NULL, VIRSH_CUSTOM, "-q", "domname"= , "4294967298"); DO_TEST_FULL("schedinfo-invalid-argument", NULL, VIRSH_DEFAULT, "sched= info", "1", "--set", "j=3Dk"); + DO_TEST_FULL("pool-define-as", NULL, VIRSH_DEFAULT, "-q", + "pool-define-as", "--print-xml", "P", "dir", "src-host", + "/src/path", "/src/dev", "S", "/target-path"); DO_TEST_SCRIPT("snapshot", " + P + + + + + S + + + /target-path + + --=20 2.44.0 _______________________________________________ Devel mailing list -- devel@lists.libvirt.org To unsubscribe send an email to devel-leave@lists.libvirt.org