The 'fake' status XML testing we were doing until now was terrible and
would not catch most of the problems. Also the code was too complicated.
This adds a way simpler approach which actually works. (for the small
price of adding a lot of test data lines)
Peter Krempa (7):
tests: qemuxml2xml: Rename testInfoFree to testInfoClear
tests: qemuxml2xml: Remove testing with allowed format detection
tests: qemuxml2xml: Add proper domain status XML testing
tests: qemuxml2xml: Remove fake status XML testing
tests: util: Remove callback from testCompareDomXML2XMLFiles
tests: qemuxml2xml: Add modern example of status XML to the test
tests: qemuxml2xml: Add status XML with outgoing migration with NBD
tests/Makefile.am | 1 +
tests/genericxml2xmltest.c | 2 +-
tests/lxcxml2xmltest.c | 2 +-
tests/qemustatusxml2xmldata/blockjob-mirror-in.xml | 96 +++++
.../qemustatusxml2xmldata/blockjob-mirror-out.xml | 96 +++++
.../qemustatusxml2xmldata/migration-out-nbd-in.xml | 449 +++++++++++++++++++++
.../migration-out-nbd-out.xml | 449 +++++++++++++++++++++
tests/qemustatusxml2xmldata/modern-in.xml | 443 ++++++++++++++++++++
tests/qemustatusxml2xmldata/modern-out.xml | 443 ++++++++++++++++++++
tests/qemustatusxml2xmldata/vcpus-multi-in.xml | 343 ++++++++++++++++
tests/qemustatusxml2xmldata/vcpus-multi-out.xml | 343 ++++++++++++++++
.../qemuxml2argvdata/disk-drive-detect-zeroes.xml | 2 +-
tests/qemuxml2argvdata/hugepages-memaccess.xml | 1 +
tests/qemuxml2argvdata/hugepages-memaccess2.xml | 1 +
tests/qemuxml2argvdata/hugepages-pages4.xml | 1 +
tests/qemuxml2argvdata/hugepages-pages5.xml | 1 +
tests/qemuxml2argvdata/hugepages-pages6.xml | 1 +
.../memory-hotplug-nvdimm-access.xml | 1 +
.../memory-hotplug-nvdimm-label.xml | 1 +
tests/qemuxml2argvdata/memory-hotplug-nvdimm.xml | 1 +
.../serial-tcp-tlsx509-chardev-notls.xml | 1 +
.../aarch64-aavmf-virtio-mmio.xml | 1 +
.../aarch64-virtio-pci-default.xml | 1 +
.../aarch64-virtio-pci-manual-addresses.xml | 1 +
tests/qemuxml2xmloutdata/autoindex.xml | 1 +
tests/qemuxml2xmloutdata/balloon-device-auto.xml | 1 +
tests/qemuxml2xmloutdata/balloon-device-period.xml | 1 +
.../bios-nvram-os-interleave.xml | 1 +
tests/qemuxml2xmloutdata/bios-nvram.xml | 1 +
tests/qemuxml2xmloutdata/blkiotune-device.xml | 1 +
tests/qemuxml2xmloutdata/blkiotune.xml | 1 +
.../boot-menu-disable-with-timeout.xml | 1 +
tests/qemuxml2xmloutdata/boot-menu-disable.xml | 1 +
.../boot-menu-enable-with-timeout.xml | 1 +
tests/qemuxml2xmloutdata/boot-multi.xml | 1 +
tests/qemuxml2xmloutdata/boot-order.xml | 2 +
tests/qemuxml2xmloutdata/channel-guestfwd.xml | 1 +
tests/qemuxml2xmloutdata/channel-virtio-auto.xml | 1 +
.../channel-virtio-state-active.xml | 1 +
.../channel-virtio-state-inactive.xml | 1 +
tests/qemuxml2xmloutdata/channel-virtio.xml | 1 +
tests/qemuxml2xmloutdata/clock-catchup.xml | 1 +
tests/qemuxml2xmloutdata/console-compat-auto.xml | 1 +
tests/qemuxml2xmloutdata/console-virtio-many.xml | 1 +
tests/qemuxml2xmloutdata/console-virtio.xml | 1 +
.../cpu-host-passthrough-features.xml | 1 +
tests/qemuxml2xmloutdata/cputune-iothreads.xml | 1 +
.../cputune-iothreadsched-zeropriority.xml | 1 +
tests/qemuxml2xmloutdata/cputune-iothreadsched.xml | 1 +
tests/qemuxml2xmloutdata/cputune-zero-shares.xml | 1 +
tests/qemuxml2xmloutdata/cputune.xml | 1 +
.../qemuxml2xmloutdata/disk-drive-copy-on-read.xml | 2 +-
tests/qemuxml2xmloutdata/disk-drive-discard.xml | 2 +-
tests/qemuxml2xmloutdata/disk-mirror-active.xml | 5 +
tests/qemuxml2xmloutdata/disk-mirror-inactive.xml | 4 +
.../disk-mirror-old-inactive.xml | 4 +
tests/qemuxml2xmloutdata/disk-mirror-old.xml | 7 +-
tests/qemuxml2xmloutdata/disk-scsi-device-auto.xml | 2 +
tests/qemuxml2xmloutdata/disk-scsi-device.xml | 2 +
tests/qemuxml2xmloutdata/disk-scsi-disk-vpd.xml | 2 +
.../disk-scsi-lun-passthrough-sgio.xml | 2 +
tests/qemuxml2xmloutdata/disk-scsi-megasas.xml | 2 +
tests/qemuxml2xmloutdata/disk-scsi-mptsas1068.xml | 2 +
tests/qemuxml2xmloutdata/disk-scsi-virtio-scsi.xml | 2 +
tests/qemuxml2xmloutdata/disk-scsi-vscsi.xml | 2 +
tests/qemuxml2xmloutdata/disk-serial.xml | 3 +
tests/qemuxml2xmloutdata/disk-source-pool-mode.xml | 4 +
tests/qemuxml2xmloutdata/disk-source-pool.xml | 2 +
tests/qemuxml2xmloutdata/disk-usb-device.xml | 2 +
.../disk-virtio-scsi-cmd_per_lun.xml | 1 +
.../disk-virtio-scsi-ioeventfd.xml | 1 +
.../disk-virtio-scsi-max_sectors.xml | 1 +
.../disk-virtio-scsi-num_queues.xml | 1 +
.../qemuxml2xmloutdata/graphics-listen-network.xml | 1 +
.../graphics-listen-network2.xml | 1 +
.../graphics-spice-compression.xml | 1 +
.../qemuxml2xmloutdata/graphics-spice-qxl-vga.xml | 1 +
tests/qemuxml2xmloutdata/graphics-spice.xml | 1 +
.../hostdev-scsi-autogen-address.xml | 1 +
.../qemuxml2xmloutdata/hostdev-scsi-large-unit.xml | 1 +
.../hostdev-scsi-lsi-iscsi-auth.xml | 1 +
.../qemuxml2xmloutdata/hostdev-scsi-lsi-iscsi.xml | 1 +
tests/qemuxml2xmloutdata/hostdev-scsi-lsi.xml | 1 +
tests/qemuxml2xmloutdata/hostdev-scsi-rawio.xml | 1 +
tests/qemuxml2xmloutdata/hostdev-scsi-readonly.xml | 1 +
tests/qemuxml2xmloutdata/hostdev-scsi-sgio.xml | 1 +
.../qemuxml2xmloutdata/hostdev-scsi-shareable.xml | 1 +
.../hostdev-scsi-vhost-scsi-ccw.xml | 1 +
.../hostdev-scsi-vhost-scsi-pci.xml | 1 +
.../hostdev-scsi-virtio-iscsi-auth.xml | 1 +
.../hostdev-scsi-virtio-iscsi.xml | 1 +
.../hostdev-scsi-virtio-scsi.xml | 1 +
tests/qemuxml2xmloutdata/hostdev-vfio.xml | 1 +
tests/qemuxml2xmloutdata/hugepages-pages.xml | 1 +
tests/qemuxml2xmloutdata/hugepages-pages2.xml | 1 +
tests/qemuxml2xmloutdata/hugepages-pages3.xml | 1 +
tests/qemuxml2xmloutdata/hugepages-shared.xml | 1 +
tests/qemuxml2xmloutdata/hugepages.xml | 1 +
tests/qemuxml2xmloutdata/lease.xml | 2 +
.../machine-loadparm-multiple-disks-nets-s390.xml | 2 +
tests/qemuxml2xmloutdata/memory-hotplug-dimm.xml | 1 +
tests/qemuxml2xmloutdata/memory-hotplug.xml | 1 +
tests/qemuxml2xmloutdata/memtune-unlimited.xml | 1 +
tests/qemuxml2xmloutdata/memtune.xml | 1 +
tests/qemuxml2xmloutdata/metadata-duplicate.xml | 1 +
tests/qemuxml2xmloutdata/metadata.xml | 1 +
tests/qemuxml2xmloutdata/minimal.xml | 1 +
tests/qemuxml2xmloutdata/net-hostdev-vfio.xml | 1 +
tests/qemuxml2xmloutdata/net-hostdev.xml | 1 +
tests/qemuxml2xmloutdata/net-midonet.xml | 1 +
tests/qemuxml2xmloutdata/net-openvswitch.xml | 1 +
tests/qemuxml2xmloutdata/net-udp.xml | 1 +
tests/qemuxml2xmloutdata/net-virtio-device.xml | 1 +
.../net-virtio-disable-offloads.xml | 1 +
.../net-virtio-network-portgroup.xml | 1 +
.../net-virtio-rxtxqueuesize.xml | 1 +
.../numad-auto-memory-vcpu-cpuset.xml | 1 +
...ad-auto-memory-vcpu-no-cpuset-and-placement.xml | 1 +
.../numad-auto-vcpu-no-numatune.xml | 1 +
.../numad-static-vcpu-no-numatune.xml | 1 +
tests/qemuxml2xmloutdata/panic-isa.xml | 1 +
tests/qemuxml2xmloutdata/panic-no-address.xml | 1 +
tests/qemuxml2xmloutdata/panic.xml | 1 +
tests/qemuxml2xmloutdata/pci-rom.xml | 1 +
.../qemuxml2xmloutdata/pci-serial-dev-chardev.xml | 1 +
tests/qemuxml2xmloutdata/pcie-expander-bus.xml | 1 +
tests/qemuxml2xmloutdata/pcie-root-port.xml | 1 +
.../pcie-switch-downstream-port.xml | 1 +
.../pcie-switch-upstream-port.xml | 1 +
tests/qemuxml2xmloutdata/pcihole64-q35.xml | 1 +
tests/qemuxml2xmloutdata/q35-pcie-autoadd.xml | 1 +
tests/qemuxml2xmloutdata/q35-pcie.xml | 1 +
tests/qemuxml2xmloutdata/q35-usb2-multi.xml | 1 +
tests/qemuxml2xmloutdata/q35-usb2-reorder.xml | 1 +
tests/qemuxml2xmloutdata/q35-usb2.xml | 1 +
tests/qemuxml2xmloutdata/q35-virtio-pci.xml | 1 +
tests/qemuxml2xmloutdata/q35.xml | 1 +
tests/qemuxml2xmloutdata/seclabel-dac-none.xml | 1 +
.../seclabel-device-multiple.xml | 1 +
.../seclabel-dynamic-baselabel.xml | 1 +
.../seclabel-dynamic-labelskip.xml | 1 +
tests/qemuxml2xmloutdata/seclabel-dynamic-none.xml | 1 +
.../seclabel-dynamic-override.xml | 2 +
.../seclabel-dynamic-relabel.xml | 1 +
tests/qemuxml2xmloutdata/seclabel-none.xml | 1 +
.../seclabel-static-labelskip.xml | 1 +
tests/qemuxml2xmloutdata/seclabel-static.xml | 1 +
.../serial-spiceport-nospice.xml | 1 +
tests/qemuxml2xmloutdata/serial-spiceport.xml | 1 +
.../qemuxml2xmloutdata/serial-target-port-auto.xml | 1 +
.../serial-tcp-tlsx509-chardev.xml | 1 +
tests/qemuxml2xmloutdata/smbios-multiple-type2.xml | 1 +
tests/qemuxml2xmloutdata/smbios.xml | 1 +
tests/qemuxml2xmloutdata/sound-device.xml | 1 +
tests/qemuxml2xmloutdata/video-qxl-heads.xml | 1 +
tests/qemuxml2xmloutdata/video-qxl-noheads.xml | 1 +
tests/qemuxml2xmloutdata/vmcoreinfo.xml | 1 +
tests/qemuxml2xmltest.c | 283 ++++---------
tests/testutils.c | 8 +-
tests/testutils.h | 5 -
160 files changed, 2926 insertions(+), 221 deletions(-)
create mode 100644 tests/qemustatusxml2xmldata/blockjob-mirror-in.xml
create mode 100644 tests/qemustatusxml2xmldata/blockjob-mirror-out.xml
create mode 100644 tests/qemustatusxml2xmldata/migration-out-nbd-in.xml
create mode 100644 tests/qemustatusxml2xmldata/migration-out-nbd-out.xml
create mode 100644 tests/qemustatusxml2xmldata/modern-in.xml
create mode 100644 tests/qemustatusxml2xmldata/modern-out.xml
create mode 100644 tests/qemustatusxml2xmldata/vcpus-multi-in.xml
create mode 100644 tests/qemustatusxml2xmldata/vcpus-multi-out.xml
--
2.16.2