]> git.ipfire.org Git - thirdparty/libvirt.git/commitdiff
tests: Clean up HPT tests
authorAndrea Bolognani <abologna@redhat.com>
Tue, 23 Jan 2018 09:50:04 +0000 (10:50 +0100)
committerAndrea Bolognani <abologna@redhat.com>
Tue, 13 Feb 2018 13:40:11 +0000 (14:40 +0100)
Give them better names and remove some redundancy.

Signed-off-by: Andrea Bolognani <abologna@redhat.com>
Reviewed-by: John Ferlan <jferlan@redhat.com>
tests/qemuxml2argvdata/pseries-features-hpt.args [moved from tests/qemuxml2argvdata/pseries-hpt-resizing.args with 96% similarity]
tests/qemuxml2argvdata/pseries-features-hpt.xml [moved from tests/qemuxml2xmloutdata/pseries-hpt-resizing.xml with 100% similarity]
tests/qemuxml2argvdata/pseries-features-invalid-machine.xml [moved from tests/qemuxml2argvdata/pseries-hpt-resizing-invalid-machine.xml with 86% similarity]
tests/qemuxml2argvdata/pseries-hpt-resizing.xml [deleted file]
tests/qemuxml2argvtest.c
tests/qemuxml2xmloutdata/pseries-features-hpt.xml [new symlink]
tests/qemuxml2xmltest.c

similarity index 96%
rename from tests/qemuxml2argvdata/pseries-hpt-resizing.args
rename to tests/qemuxml2argvdata/pseries-features-hpt.args
index 994789a5e0764237d705b7f7675cde5c5ce31d7a..8cdb3296513fd3adc0377601d7ccf7749de17bb9 100644 (file)
@@ -12,7 +12,6 @@ QEMU_AUDIO_DRV=none \
 -smp 1,sockets=1,cores=1,threads=1 \
 -uuid 1ccfd97d-5eb4-478a-bbe6-88d254c16db7 \
 -nographic \
--nodefconfig \
 -nodefaults \
 -chardev socket,id=charmonitor,path=/tmp/lib/domain--1-guest/monitor.sock,\
 server,nowait \
similarity index 86%
rename from tests/qemuxml2argvdata/pseries-hpt-resizing-invalid-machine.xml
rename to tests/qemuxml2argvdata/pseries-features-invalid-machine.xml
index 757fcc70e11e44d430452c90a902e98f117bada4..5a6bb02d5b6051f5d2c92b249acc318f0c9c3769 100644 (file)
@@ -7,7 +7,7 @@
     <type arch='x86_64' machine='pc'>hvm</type>
   </os>
   <features>
-    <!-- HPT resizing can't be enabled for non-pSeries guests -->
+    <!-- pSeries features can't be enabled for non-pSeries guests -->
     <hpt resizing='enabled'/>
   </features>
   <devices>
diff --git a/tests/qemuxml2argvdata/pseries-hpt-resizing.xml b/tests/qemuxml2argvdata/pseries-hpt-resizing.xml
deleted file mode 100644 (file)
index f9dc9ca..0000000
+++ /dev/null
@@ -1,19 +0,0 @@
-<domain type='qemu'>
-  <name>guest</name>
-  <uuid>1ccfd97d-5eb4-478a-bbe6-88d254c16db7</uuid>
-  <memory unit='KiB'>524288</memory>
-  <vcpu placement='static'>1</vcpu>
-  <os>
-    <type arch='ppc64' machine='pseries'>hvm</type>
-  </os>
-  <features>
-    <!-- Explicitly enable HPT resizing. The guest will not start
-         at all unless HPT resizing can be arranged -->
-    <hpt resizing='required'/>
-  </features>
-  <devices>
-    <emulator>/usr/bin/qemu-system-ppc64</emulator>
-    <controller type='usb' model='none'/>
-    <memballoon model='none'/>
-  </devices>
-</domain>
index fec4da3652d2a97da120a167da596933ae11dd07..ade18c055088a7792b8e4e1fc686843e599dcc27 100644 (file)
@@ -1895,17 +1895,12 @@ mymain(void)
             QEMU_CAPS_VIRTIO_SCSI,
             QEMU_CAPS_DEVICE_VFIO_PCI);
 
-    DO_TEST("pseries-hpt-resizing",
-            QEMU_CAPS_NODEFCONFIG,
+    DO_TEST("pseries-features-hpt",
             QEMU_CAPS_MACHINE_OPT,
             QEMU_CAPS_MACHINE_PSERIES_RESIZE_HPT);
-    DO_TEST_FAILURE("pseries-hpt-resizing",
-                    QEMU_CAPS_NODEFCONFIG,
+    DO_TEST_FAILURE("pseries-features-hpt",
                     QEMU_CAPS_MACHINE_OPT);
-    DO_TEST_PARSE_ERROR("pseries-hpt-resizing-invalid-machine",
-                        QEMU_CAPS_NODEFCONFIG,
-                        QEMU_CAPS_MACHINE_OPT,
-                        QEMU_CAPS_MACHINE_PSERIES_RESIZE_HPT);
+    DO_TEST_PARSE_ERROR("pseries-features-invalid-machine", NONE);
 
     DO_TEST("pseries-serial-native",
             QEMU_CAPS_NODEFCONFIG,
diff --git a/tests/qemuxml2xmloutdata/pseries-features-hpt.xml b/tests/qemuxml2xmloutdata/pseries-features-hpt.xml
new file mode 120000 (symlink)
index 0000000..bcaf2e6
--- /dev/null
@@ -0,0 +1 @@
+../qemuxml2argvdata/pseries-features-hpt.xml
\ No newline at end of file
index 83809574c3d0c7259e8236333c0f90cf27786b52..0eb9e6c77a77c203e60c7d4035fd8143842fed9e 100644 (file)
@@ -763,8 +763,7 @@ mymain(void)
             QEMU_CAPS_VIRTIO_SCSI,
             QEMU_CAPS_DEVICE_VFIO_PCI);
 
-    DO_TEST("pseries-hpt-resizing",
-            QEMU_CAPS_NODEFCONFIG,
+    DO_TEST("pseries-features-hpt",
             QEMU_CAPS_MACHINE_OPT,
             QEMU_CAPS_MACHINE_PSERIES_RESIZE_HPT);