From 14ded7bb83d2c7ffb7cd20c4e7a477749c196380 Mon Sep 17 00:00:00 2001 From: Peter Krempa Date: Thu, 19 Jul 2018 16:26:48 +0200 Subject: [PATCH] tests: qemu: Unify nbd disk source testing MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Peter Krempa Reviewed-by: Ján Tomko --- .../disk-network-nbd-export.args | 30 ------------- .../disk-network-nbd-export.xml | 37 ---------------- .../disk-network-nbd-ipv6-export.args | 29 ------------- .../disk-network-nbd-ipv6-export.xml | 37 ---------------- .../disk-network-nbd-ipv6.args | 29 ------------- .../disk-network-nbd-ipv6.xml | 37 ---------------- .../disk-network-nbd-unix.args | 30 ------------- .../disk-network-nbd-unix.xml | 37 ---------------- tests/qemuxml2argvdata/disk-network-nbd.args | 18 ++++++-- tests/qemuxml2argvdata/disk-network-nbd.xml | 34 ++++++++++++--- tests/qemuxml2argvtest.c | 4 -- .../disk-network-nbd-export.xml | 42 ------------------- .../disk-network-nbd-ipv6-export.xml | 42 ------------------- .../disk-network-nbd-ipv6.xml | 42 ------------------- .../disk-network-nbd-unix.xml | 42 ------------------- tests/qemuxml2xmloutdata/disk-network-nbd.xml | 38 ++++++++++++++--- tests/qemuxml2xmltest.c | 4 -- 17 files changed, 75 insertions(+), 457 deletions(-) delete mode 100644 tests/qemuxml2argvdata/disk-network-nbd-export.args delete mode 100644 tests/qemuxml2argvdata/disk-network-nbd-export.xml delete mode 100644 tests/qemuxml2argvdata/disk-network-nbd-ipv6-export.args delete mode 100644 tests/qemuxml2argvdata/disk-network-nbd-ipv6-export.xml delete mode 100644 tests/qemuxml2argvdata/disk-network-nbd-ipv6.args delete mode 100644 tests/qemuxml2argvdata/disk-network-nbd-ipv6.xml delete mode 100644 tests/qemuxml2argvdata/disk-network-nbd-unix.args delete mode 100644 tests/qemuxml2argvdata/disk-network-nbd-unix.xml delete mode 100644 tests/qemuxml2xmloutdata/disk-network-nbd-export.xml delete mode 100644 tests/qemuxml2xmloutdata/disk-network-nbd-ipv6-export.xml delete mode 100644 tests/qemuxml2xmloutdata/disk-network-nbd-ipv6.xml delete mode 100644 tests/qemuxml2xmloutdata/disk-network-nbd-unix.xml diff --git a/tests/qemuxml2argvdata/disk-network-nbd-export.args b/tests/qemuxml2argvdata/disk-network-nbd-export.args deleted file mode 100644 index ff220d3f7d..0000000000 --- a/tests/qemuxml2argvdata/disk-network-nbd-export.args +++ /dev/null @@ -1,30 +0,0 @@ -LC_ALL=C \ -PATH=/bin \ -HOME=/home/test \ -USER=test \ -LOGNAME=test \ -QEMU_AUDIO_DRV=none \ -/usr/bin/qemu-system-i686 \ --name QEMUGuest1 \ --S \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ --m 214 \ --smp 1,sockets=1,cores=1,threads=1 \ --uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ --display none \ --no-user-config \ --nodefaults \ --chardev socket,id=charmonitor,path=/tmp/lib/domain--1-QEMUGuest1/monitor.sock,\ -server,nowait \ --mon chardev=charmonitor,id=monitor,mode=control \ --rtc base=utc \ --no-shutdown \ --no-acpi \ --boot c \ --usb \ --drive file=/dev/HostVG/QEMUGuest1,format=raw,if=none,id=drive-ide0-0-0 \ --device ide-drive,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0 \ --drive file=nbd:example.org:6000:exportname=bar,format=raw,if=none,\ -id=drive-virtio-disk0 \ --device virtio-blk-pci,bus=pci.0,addr=0x3,drive=drive-virtio-disk0,\ -id=virtio-disk0 diff --git a/tests/qemuxml2argvdata/disk-network-nbd-export.xml b/tests/qemuxml2argvdata/disk-network-nbd-export.xml deleted file mode 100644 index 2acf380c35..0000000000 --- a/tests/qemuxml2argvdata/disk-network-nbd-export.xml +++ /dev/null @@ -1,37 +0,0 @@ - - QEMUGuest1 - c7a5fdbd-edaf-9455-926a-d65c16db1809 - 219136 - 219136 - 1 - - hvm - - - - destroy - restart - destroy - - /usr/bin/qemu-system-i686 - - - - -
- - - - - - - - - - - - - - - - diff --git a/tests/qemuxml2argvdata/disk-network-nbd-ipv6-export.args b/tests/qemuxml2argvdata/disk-network-nbd-ipv6-export.args deleted file mode 100644 index 8ced242f52..0000000000 --- a/tests/qemuxml2argvdata/disk-network-nbd-ipv6-export.args +++ /dev/null @@ -1,29 +0,0 @@ -LC_ALL=C \ -PATH=/bin \ -HOME=/home/test \ -USER=test \ -LOGNAME=test \ -QEMU_AUDIO_DRV=none \ -/usr/bin/qemu-system-i686 \ --name QEMUGuest1 \ --S \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ --m 214 \ --smp 1,sockets=1,cores=1,threads=1 \ --uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ --display none \ --no-user-config \ --nodefaults \ --chardev socket,id=charmonitor,path=/tmp/lib/domain--1-QEMUGuest1/monitor.sock,\ -server,nowait \ --mon chardev=charmonitor,id=monitor,mode=control \ --rtc base=utc \ --no-shutdown \ --no-acpi \ --boot c \ --usb \ --drive file=/dev/HostVG/QEMUGuest1,format=raw,if=none,id=drive-ide0-0-0 \ --device ide-drive,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0 \ --drive 'file=nbd://[::1]:6000/bar,format=raw,if=none,id=drive-virtio-disk0' \ --device virtio-blk-pci,bus=pci.0,addr=0x3,drive=drive-virtio-disk0,\ -id=virtio-disk0 diff --git a/tests/qemuxml2argvdata/disk-network-nbd-ipv6-export.xml b/tests/qemuxml2argvdata/disk-network-nbd-ipv6-export.xml deleted file mode 100644 index da50dc5e81..0000000000 --- a/tests/qemuxml2argvdata/disk-network-nbd-ipv6-export.xml +++ /dev/null @@ -1,37 +0,0 @@ - - QEMUGuest1 - c7a5fdbd-edaf-9455-926a-d65c16db1809 - 219136 - 219136 - 1 - - hvm - - - - destroy - restart - destroy - - /usr/bin/qemu-system-i686 - - - - -
- - - - - - - - - - - - - - - - diff --git a/tests/qemuxml2argvdata/disk-network-nbd-ipv6.args b/tests/qemuxml2argvdata/disk-network-nbd-ipv6.args deleted file mode 100644 index e3e2677354..0000000000 --- a/tests/qemuxml2argvdata/disk-network-nbd-ipv6.args +++ /dev/null @@ -1,29 +0,0 @@ -LC_ALL=C \ -PATH=/bin \ -HOME=/home/test \ -USER=test \ -LOGNAME=test \ -QEMU_AUDIO_DRV=none \ -/usr/bin/qemu-system-i686 \ --name QEMUGuest1 \ --S \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ --m 214 \ --smp 1,sockets=1,cores=1,threads=1 \ --uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ --display none \ --no-user-config \ --nodefaults \ --chardev socket,id=charmonitor,path=/tmp/lib/domain--1-QEMUGuest1/monitor.sock,\ -server,nowait \ --mon chardev=charmonitor,id=monitor,mode=control \ --rtc base=utc \ --no-shutdown \ --no-acpi \ --boot c \ --usb \ --drive file=/dev/HostVG/QEMUGuest1,format=raw,if=none,id=drive-ide0-0-0 \ --device ide-drive,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0 \ --drive 'file=nbd://[::1]:6000,format=raw,if=none,id=drive-virtio-disk0' \ --device virtio-blk-pci,bus=pci.0,addr=0x3,drive=drive-virtio-disk0,\ -id=virtio-disk0 diff --git a/tests/qemuxml2argvdata/disk-network-nbd-ipv6.xml b/tests/qemuxml2argvdata/disk-network-nbd-ipv6.xml deleted file mode 100644 index 4c4dcdd7a6..0000000000 --- a/tests/qemuxml2argvdata/disk-network-nbd-ipv6.xml +++ /dev/null @@ -1,37 +0,0 @@ - - QEMUGuest1 - c7a5fdbd-edaf-9455-926a-d65c16db1809 - 219136 - 219136 - 1 - - hvm - - - - destroy - restart - destroy - - /usr/bin/qemu-system-i686 - - - - -
- - - - - - - - - - - - - - - - diff --git a/tests/qemuxml2argvdata/disk-network-nbd-unix.args b/tests/qemuxml2argvdata/disk-network-nbd-unix.args deleted file mode 100644 index 6c485f95fa..0000000000 --- a/tests/qemuxml2argvdata/disk-network-nbd-unix.args +++ /dev/null @@ -1,30 +0,0 @@ -LC_ALL=C \ -PATH=/bin \ -HOME=/home/test \ -USER=test \ -LOGNAME=test \ -QEMU_AUDIO_DRV=none \ -/usr/bin/qemu-system-i686 \ --name QEMUGuest1 \ --S \ --machine pc,accel=tcg,usb=off,dump-guest-core=off \ --m 214 \ --smp 1,sockets=1,cores=1,threads=1 \ --uuid c7a5fdbd-edaf-9455-926a-d65c16db1809 \ --display none \ --no-user-config \ --nodefaults \ --chardev socket,id=charmonitor,path=/tmp/lib/domain--1-QEMUGuest1/monitor.sock,\ -server,nowait \ --mon chardev=charmonitor,id=monitor,mode=control \ --rtc base=utc \ --no-shutdown \ --no-acpi \ --boot c \ --usb \ --drive file=/dev/HostVG/QEMUGuest1,format=raw,if=none,id=drive-ide0-0-0 \ --device ide-drive,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0 \ --drive file=nbd:unix:/var/run/nbdsock:exportname=bar,format=raw,if=none,\ -id=drive-virtio-disk0 \ --device virtio-blk-pci,bus=pci.0,addr=0x3,drive=drive-virtio-disk0,\ -id=virtio-disk0 diff --git a/tests/qemuxml2argvdata/disk-network-nbd-unix.xml b/tests/qemuxml2argvdata/disk-network-nbd-unix.xml deleted file mode 100644 index 3921f3fab2..0000000000 --- a/tests/qemuxml2argvdata/disk-network-nbd-unix.xml +++ /dev/null @@ -1,37 +0,0 @@ - - QEMUGuest1 - c7a5fdbd-edaf-9455-926a-d65c16db1809 - 219136 - 219136 - 1 - - hvm - - - - destroy - restart - destroy - - /usr/bin/qemu-system-i686 - - - - -
- - - - - - - - - - - - - - - - diff --git a/tests/qemuxml2argvdata/disk-network-nbd.args b/tests/qemuxml2argvdata/disk-network-nbd.args index caf2bd5c72..8f10e78e0c 100644 --- a/tests/qemuxml2argvdata/disk-network-nbd.args +++ b/tests/qemuxml2argvdata/disk-network-nbd.args @@ -22,8 +22,20 @@ server,nowait \ -no-acpi \ -boot c \ -usb \ --drive file=/dev/HostVG/QEMUGuest1,format=raw,if=none,id=drive-ide0-0-0 \ --device ide-drive,bus=ide.0,unit=0,drive=drive-ide0-0-0,id=ide0-0-0 \ -drive file=nbd:example.org:6000,format=raw,if=none,id=drive-virtio-disk0 \ -device virtio-blk-pci,bus=pci.0,addr=0x3,drive=drive-virtio-disk0,\ -id=virtio-disk0 +id=virtio-disk0 \ +-drive file=nbd:example.org:6000:exportname=bar,format=raw,if=none,\ +id=drive-virtio-disk1 \ +-device virtio-blk-pci,bus=pci.0,addr=0x4,drive=drive-virtio-disk1,\ +id=virtio-disk1 \ +-drive 'file=nbd://[::1]:6000,format=raw,if=none,id=drive-virtio-disk2' \ +-device virtio-blk-pci,bus=pci.0,addr=0x5,drive=drive-virtio-disk2,\ +id=virtio-disk2 \ +-drive 'file=nbd://[::1]:6000/bar,format=raw,if=none,id=drive-virtio-disk3' \ +-device virtio-blk-pci,bus=pci.0,addr=0x6,drive=drive-virtio-disk3,\ +id=virtio-disk3 \ +-drive file=nbd:unix:/var/run/nbdsock:exportname=bar,format=raw,if=none,\ +id=drive-virtio-disk4 \ +-device virtio-blk-pci,bus=pci.0,addr=0x7,drive=drive-virtio-disk4,\ +id=virtio-disk4 diff --git a/tests/qemuxml2argvdata/disk-network-nbd.xml b/tests/qemuxml2argvdata/disk-network-nbd.xml index 00f627bc59..2d5762f1b7 100644 --- a/tests/qemuxml2argvdata/disk-network-nbd.xml +++ b/tests/qemuxml2argvdata/disk-network-nbd.xml @@ -14,12 +14,6 @@ destroy /usr/bin/qemu-system-i686 - - - - -
- @@ -27,6 +21,34 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + diff --git a/tests/qemuxml2argvtest.c b/tests/qemuxml2argvtest.c index 2dfb0da267..d4d98bfe21 100644 --- a/tests/qemuxml2argvtest.c +++ b/tests/qemuxml2argvtest.c @@ -1037,10 +1037,6 @@ mymain(void) DO_TEST_CAPS_VER("disk-cache", "2.7.0"); DO_TEST_CAPS_LATEST("disk-cache"); DO_TEST("disk-network-nbd", NONE); - DO_TEST("disk-network-nbd-export", NONE); - DO_TEST("disk-network-nbd-ipv6", NONE); - DO_TEST("disk-network-nbd-ipv6-export", NONE); - DO_TEST("disk-network-nbd-unix", NONE); DO_TEST("disk-network-iscsi", QEMU_CAPS_VIRTIO_SCSI, QEMU_CAPS_SCSI_BLOCK); DO_TEST_CAPS_LATEST("disk-network-iscsi"); DO_TEST_PARSE_ERROR("disk-network-iscsi-auth-secrettype-invalid", NONE); diff --git a/tests/qemuxml2xmloutdata/disk-network-nbd-export.xml b/tests/qemuxml2xmloutdata/disk-network-nbd-export.xml deleted file mode 100644 index c4754c324c..0000000000 --- a/tests/qemuxml2xmloutdata/disk-network-nbd-export.xml +++ /dev/null @@ -1,42 +0,0 @@ - - QEMUGuest1 - c7a5fdbd-edaf-9455-926a-d65c16db1809 - 219136 - 219136 - 1 - - hvm - - - - destroy - restart - destroy - - /usr/bin/qemu-system-i686 - - - - -
- - - - - - - -
- - -
- - -
- - - - - - - diff --git a/tests/qemuxml2xmloutdata/disk-network-nbd-ipv6-export.xml b/tests/qemuxml2xmloutdata/disk-network-nbd-ipv6-export.xml deleted file mode 100644 index 5e961b58f5..0000000000 --- a/tests/qemuxml2xmloutdata/disk-network-nbd-ipv6-export.xml +++ /dev/null @@ -1,42 +0,0 @@ - - QEMUGuest1 - c7a5fdbd-edaf-9455-926a-d65c16db1809 - 219136 - 219136 - 1 - - hvm - - - - destroy - restart - destroy - - /usr/bin/qemu-system-i686 - - - - -
- - - - - - - -
- - -
- - -
- - - - - - - diff --git a/tests/qemuxml2xmloutdata/disk-network-nbd-ipv6.xml b/tests/qemuxml2xmloutdata/disk-network-nbd-ipv6.xml deleted file mode 100644 index 7e1afff97b..0000000000 --- a/tests/qemuxml2xmloutdata/disk-network-nbd-ipv6.xml +++ /dev/null @@ -1,42 +0,0 @@ - - QEMUGuest1 - c7a5fdbd-edaf-9455-926a-d65c16db1809 - 219136 - 219136 - 1 - - hvm - - - - destroy - restart - destroy - - /usr/bin/qemu-system-i686 - - - - -
- - - - - - - -
- - -
- - -
- - - - - - - diff --git a/tests/qemuxml2xmloutdata/disk-network-nbd-unix.xml b/tests/qemuxml2xmloutdata/disk-network-nbd-unix.xml deleted file mode 100644 index 02c3f64f75..0000000000 --- a/tests/qemuxml2xmloutdata/disk-network-nbd-unix.xml +++ /dev/null @@ -1,42 +0,0 @@ - - QEMUGuest1 - c7a5fdbd-edaf-9455-926a-d65c16db1809 - 219136 - 219136 - 1 - - hvm - - - - destroy - restart - destroy - - /usr/bin/qemu-system-i686 - - - - -
- - - - - - - -
- - -
- - -
- - - - - - - diff --git a/tests/qemuxml2xmloutdata/disk-network-nbd.xml b/tests/qemuxml2xmloutdata/disk-network-nbd.xml index 165b61b348..818e8d7d7c 100644 --- a/tests/qemuxml2xmloutdata/disk-network-nbd.xml +++ b/tests/qemuxml2xmloutdata/disk-network-nbd.xml @@ -14,12 +14,6 @@ destroy /usr/bin/qemu-system-i686 - - - - -
- @@ -28,6 +22,38 @@
+ + + + + + +
+ + + + + + + +
+ + + + + + + +
+ + + + + + + +
+
diff --git a/tests/qemuxml2xmltest.c b/tests/qemuxml2xmltest.c index edba1ca99d..b2aa903ec9 100644 --- a/tests/qemuxml2xmltest.c +++ b/tests/qemuxml2xmltest.c @@ -359,10 +359,6 @@ mymain(void) DO_TEST("disk-fmt-qcow", NONE); DO_TEST("disk-cache", QEMU_CAPS_SCSI_LSI); DO_TEST("disk-network-nbd", NONE); - DO_TEST("disk-network-nbd-export", NONE); - DO_TEST("disk-network-nbd-ipv6", NONE); - DO_TEST("disk-network-nbd-ipv6-export", NONE); - DO_TEST("disk-network-nbd-unix", NONE); DO_TEST("disk-network-iscsi", QEMU_CAPS_VIRTIO_SCSI); DO_TEST("disk-network-gluster", NONE); DO_TEST("disk-network-rbd", NONE); -- GitLab