From nobody Wed Feb 11 10:17:14 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of redhat.com designates 209.132.183.37 as permitted sender) client-ip=209.132.183.37; envelope-from=libvir-list-bounces@redhat.com; helo=mx5-phx2.redhat.com; Authentication-Results: mx.zoho.com; spf=pass (zoho.com: domain of redhat.com designates 209.132.183.37 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; Return-Path: Received: from mx5-phx2.redhat.com (mx5-phx2.redhat.com [209.132.183.37]) by mx.zohomail.com with SMTPS id 1489596021030499.9463756370085; Wed, 15 Mar 2017 09:40:21 -0700 (PDT) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by mx5-phx2.redhat.com (8.14.4/8.14.4) with ESMTP id v2FGbAq8016535; Wed, 15 Mar 2017 12:37:10 -0400 Received: from int-mx10.intmail.prod.int.phx2.redhat.com (int-mx10.intmail.prod.int.phx2.redhat.com [10.5.11.23]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id v2FGb7NC025077 for ; Wed, 15 Mar 2017 12:37:07 -0400 Received: from angien.brq.redhat.com (dhcp129-47.brq.redhat.com [10.34.129.47]) by int-mx10.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id v2FGafIZ000870; Wed, 15 Mar 2017 12:37:07 -0400 From: Peter Krempa To: libvir-list@redhat.com Date: Wed, 15 Mar 2017 17:37:33 +0100 Message-Id: <2c224cf07a659fbf1e18ac6997f50f400b14a589.1489595335.git.pkrempa@redhat.com> In-Reply-To: References: In-Reply-To: References: X-Scanned-By: MIMEDefang 2.68 on 10.5.11.23 X-loop: libvir-list@redhat.com Cc: Peter Krempa Subject: [libvirt] [PATCH 21/23] tests: qemumonitorjson: Test node name detection on networked storage 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: , MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-ZohoMail: RSF_0 Z_629925259 SPT_0 Content-Type: text/plain; charset="utf-8" --- .../qemumonitorjson-nodename-gluster.json | 135 +++++++++++++++++= ++++ .../qemumonitorjson-nodename-gluster.result | 10 ++ tests/qemumonitorjsontest.c | 1 + 3 files changed, 146 insertions(+) create mode 100644 tests/qemumonitorjsondata/qemumonitorjson-nodename-glus= ter.json create mode 100644 tests/qemumonitorjsondata/qemumonitorjson-nodename-glus= ter.result diff --git a/tests/qemumonitorjsondata/qemumonitorjson-nodename-gluster.jso= n b/tests/qemumonitorjsondata/qemumonitorjson-nodename-gluster.json new file mode 100644 index 000000000..7ea5c5d54 --- /dev/null +++ b/tests/qemumonitorjsondata/qemumonitorjson-nodename-gluster.json @@ -0,0 +1,135 @@ +[ + { + "iops_rd": 0, + "detect_zeroes": "off", + "image": { + "backing-image": { + "virtual-size": 197120, + "filename": "gluster://gluster-host/vol0/img0", + "format": "raw", + "actual-size": 197120 + }, + "backing-filename-format": "raw", + "virtual-size": 197120, + "filename": "gluster://gluster-host/vol0/img1", + "cluster-size": 65536, + "format": "qcow2", + "actual-size": 197120, + "format-specific": { + "type": "qcow2", + "data": { + "compat": "1.1", + "lazy-refcounts": false, + "refcount-bits": 16, + "corrupt": false + } + }, + "full-backing-filename": "gluster://gluster-host/vol0/img0", + "backing-filename": "gluster://gluster-host/vol0/img0", + "dirty-flag": false + }, + "iops_wr": 0, + "ro": false, + "node-name": "#block1008", + "backing_file_depth": 1, + "drv": "qcow2", + "iops": 0, + "bps_wr": 0, + "write_threshold": 0, + "backing_file": "gluster://gluster-host/vol0/img0", + "encrypted": false, + "bps": 0, + "bps_rd": 0, + "cache": { + "no-flush": false, + "direct": true, + "writeback": true + }, + "file": "gluster://gluster-host/vol0/img1", + "encryption_key_missing": false + }, + { + "iops_rd": 0, + "detect_zeroes": "off", + "image": { + "virtual-size": 197120, + "filename": "gluster://gluster-host/vol0/img1", + "format": "gluster", + "actual-size": 197120 + }, + "iops_wr": 0, + "ro": false, + "node-name": "#block981", + "backing_file_depth": 0, + "drv": "gluster", + "iops": 0, + "bps_wr": 0, + "write_threshold": 0, + "encrypted": false, + "bps": 0, + "bps_rd": 0, + "cache": { + "no-flush": false, + "direct": true, + "writeback": true + }, + "file": "gluster://gluster-host/vol0/img1", + "encryption_key_missing": false + }, + { + "iops_rd": 0, + "detect_zeroes": "off", + "image": { + "virtual-size": 197120, + "filename": "gluster://gluster-host/vol0/img0", + "format": "raw", + "actual-size": 197120 + }, + "iops_wr": 0, + "ro": true, + "node-name": "#block349", + "backing_file_depth": 0, + "drv": "raw", + "iops": 0, + "bps_wr": 0, + "write_threshold": 0, + "encrypted": false, + "bps": 0, + "bps_rd": 0, + "cache": { + "no-flush": false, + "direct": true, + "writeback": true + }, + "file": "gluster://gluster-host/vol0/img0", + "encryption_key_missing": false + }, + { + "iops_rd": 0, + "detect_zeroes": "off", + "image": { + "virtual-size": 197120, + "filename": "gluster://gluster-host/vol0/img0", + "format": "gluster", + "actual-size": 197120 + }, + "iops_wr": 0, + "ro": true, + "node-name": "#block269", + "backing_file_depth": 0, + "drv": "gluster", + "iops": 0, + "bps_wr": 0, + "write_threshold": 0, + "encrypted": false, + "bps": 0, + "bps_rd": 0, + "cache": { + "no-flush": false, + "direct": true, + "writeback": true + }, + "file": "gluster://gluster-host/vol0/img0", + "encryption_key_missing": false + } + ] diff --git a/tests/qemumonitorjsondata/qemumonitorjson-nodename-gluster.res= ult b/tests/qemumonitorjsondata/qemumonitorjson-nodename-gluster.result new file mode 100644 index 000000000..f38798d4b --- /dev/null +++ b/tests/qemumonitorjsondata/qemumonitorjson-nodename-gluster.result @@ -0,0 +1,10 @@ +filename : 'gluster://gluster-host/vol0/img1' +format node : '#block1008' +storage node: '#block981' +backingfile : 'gluster://gluster-host/vol0/img0' +backing ptr : '#block349' + filename : 'gluster://gluster-host/vol0/img0' + format node : '#block349' + storage node: '#block269' + backingfile : '' + backing ptr : '' diff --git a/tests/qemumonitorjsontest.c b/tests/qemumonitorjsontest.c index 5b9f24d24..4925a00b7 100644 --- a/tests/qemumonitorjsontest.c +++ b/tests/qemumonitorjsontest.c @@ -2909,6 +2909,7 @@ mymain(void) DO_TEST_BLOCK_NODE_DETECT("2", "#block161"); DO_TEST_BLOCK_NODE_DETECT("same-backing", "#block170,#block574"); DO_TEST_BLOCK_NODE_DETECT("relative", "#block153,#block1177"); + DO_TEST_BLOCK_NODE_DETECT("gluster", "#block1008"); #undef DO_TEST_BLOCK_NODE_DETECT --=20 2.12.0 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list