From nobody Sat Feb 7 08:43:54 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; spf=pass (zohomail.com: domain of redhat.com designates 170.10.133.124 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=fail(p=none dis=none) header.from=gmail.com 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 1629112446841651.5218872310506; Mon, 16 Aug 2021 04:14:06 -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-584-nJax7iYmMFOvSrb0bwoA-g-1; Mon, 16 Aug 2021 07:14:04 -0400 Received: from smtp.corp.redhat.com (int-mx03.intmail.prod.int.phx2.redhat.com [10.5.11.13]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id ADCE687D547; Mon, 16 Aug 2021 11:13:59 +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 90C9F60853; Mon, 16 Aug 2021 11:13:59 +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 32CF04A700; Mon, 16 Aug 2021 11:13:59 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.rdu2.redhat.com [10.11.54.4]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id 17GBDvK9020903 for ; Mon, 16 Aug 2021 07:13:57 -0400 Received: by smtp.corp.redhat.com (Postfix) id 1A0D4200BCBC; Mon, 16 Aug 2021 11:13:57 +0000 (UTC) Received: from mimecast-mx02.redhat.com (mimecast01.extmail.prod.ext.rdu2.redhat.com [10.11.55.17]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 155892022EC4 for ; Mon, 16 Aug 2021 11:13:57 +0000 (UTC) Received: from us-smtp-1.mimecast.com (us-smtp-delivery-1.mimecast.com [205.139.110.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id F2864866DF1 for ; Mon, 16 Aug 2021 11:13:56 +0000 (UTC) Received: from mail-pj1-f45.google.com (mail-pj1-f45.google.com [209.85.216.45]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-308-C55Xrfc_OnWZephlcVv6mA-1; Mon, 16 Aug 2021 07:13:54 -0400 Received: by mail-pj1-f45.google.com with SMTP id u13-20020a17090abb0db0290177e1d9b3f7so31793342pjr.1 for ; Mon, 16 Aug 2021 04:13:54 -0700 (PDT) Received: from localhost ([103.138.53.99]) by smtp.gmail.com with ESMTPSA id b18sm11118547pfi.199.2021.08.16.04.13.52 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 16 Aug 2021 04:13:53 -0700 (PDT) X-MC-Unique: nJax7iYmMFOvSrb0bwoA-g-1 X-MC-Unique: C55Xrfc_OnWZephlcVv6mA-1 X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=TwOvYJClj1nDujuqborhkSBWzXWjU6dJC5TmvtzRcrM=; b=Io69sml3zgcAYm+vqQlZtd/ARQpv+xnU+bLk3xa7PWi0kxgO2PcoSHWMmKZHP8weQN yW1QD6jOGLNzgV0HVpFiXOWGT0nEazDYZtNQWCyV+q8/dAWzCpFsJQSuZEflosuBIorR d4iilMqhQa22JQ9ZZ0ykKNJX5OMgKMjV8YTNmjKKWQaQNPER6kLxtpFTwrrSzP0pC6/G i2HRt6dAEBpsW/KABw7WLUkThK+kyws4E1b8fjOqoQ1j59pXJ12yUeID27WH5NXi9Cq7 vUw9GxlhIP+236/3Gd6InTyX4zQVswLDT86XnQEkCi27A4fGyvrG1JZJf+pX69gfesbU R/Tw== X-Gm-Message-State: AOAM531L4GA5RC/i6jmmlV/XLlNhGe/uP4C/tp64SNx6x84kEh3w+jlr e1ZhF7g7lDifN9RrFw+M81qzw2qMLNQGa2XhTwQ= X-Google-Smtp-Source: ABdhPJxxSCYw7LzJZtRF9CxGvMbzZTNI1Np27DBqlGV+3TH0rKmx33blogAyqG3GZAxPoDamgi411Q== X-Received: by 2002:a63:5902:: with SMTP id n2mr13486967pgb.305.1629112433464; Mon, 16 Aug 2021 04:13:53 -0700 (PDT) From: Luke Yue To: libvir-list@redhat.com Subject: [PATCH v2 4/4] virshtest: add test for domjobinfo Date: Mon, 16 Aug 2021 19:13:37 +0800 Message-Id: <20210816111337.112671-5-lukedyue@gmail.com> In-Reply-To: <20210816111337.112671-1-lukedyue@gmail.com> References: <20210816111337.112671-1-lukedyue@gmail.com> MIME-Version: 1.0 X-Mimecast-Impersonation-Protect: Policy=CLT - Impersonation Protection Definition; Similar Internal Domain=false; Similar Monitored External Domain=false; Custom External Domain=false; Mimecast External Domain=false; Newly Observed Domain=false; Internal User Name=false; Custom Display Name List=false; Reply-to Address Mismatch=false; Targeted Threat Dictionary=false; Mimecast Threat Dictionary=false; Custom Threat Dictionary=false X-Scanned-By: MIMEDefang 2.78 on 10.11.54.4 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.13 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-ZM-MESSAGEID: 1629112448169100003 Content-Type: text/plain; charset="utf-8" Signed-off-by: Luke Yue --- tests/virshtest.c | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/tests/virshtest.c b/tests/virshtest.c index 53db2aa19a..0c46496c74 100644 --- a/tests/virshtest.c +++ b/tests/virshtest.c @@ -291,6 +291,13 @@ static int testCompareDomControlInfoByName(const void = *data G_GNUC_UNUSED) return testCompareOutputLit(exp, NULL, argv); } =20 +static int testCompareDomJobInfoByName(const void *data G_GNUC_UNUSED) +{ + const char *const argv[] =3D { VIRSH_CUSTOM, "domjobinfo", "fc4", NULL= }; + const char *exp =3D "Job type: None \n\n"; + return testCompareOutputLit(exp, NULL, argv); +} + struct testInfo { const char *const *argv; const char *result; @@ -383,6 +390,10 @@ mymain(void) testCompareDomControlInfoByName, NULL) !=3D 0) ret =3D -1; =20 + if (virTestRun("virsh domjobinfo (by name)", + testCompareDomJobInfoByName, NULL) !=3D 0) + ret =3D -1; + /* It's a bit awkward listing result before argument, but that's a * limitation of C99 vararg macros. */ # define DO_TEST(i, result, ...) \ --=20 2.32.0