mirror of
https://github.com/libguestfs/libguestfs.git
synced 2026-03-21 22:53:37 +00:00
v2v: test-v2v-conversion-of.sh: basic check for libvirt XML
Use virt-xml-validate to check that the libvirt XML is actually valid, at least regarding its schema.
This commit is contained in:
@@ -81,10 +81,13 @@ EOF
|
||||
virt-v2v --debug-gc -i libvirtxml "$xml" -o local -os "$os"
|
||||
|
||||
# Test the libvirt XML metadata and a disk was created.
|
||||
# XXX We should check the XML.
|
||||
test -f "$os/$guestname.xml"
|
||||
test -f "$os/$guestname-sda"
|
||||
|
||||
# Test the libvirt XML is valid.
|
||||
# XXX This does not check bits depending on the QEMU version.
|
||||
virt-xml-validate "$os/$guestname.xml"
|
||||
|
||||
# Test the disk has a similar size to the original.
|
||||
size_before="$(du $disk | awk '{print $1}')"
|
||||
size_after="$(du $os/$guestname-sda | awk '{print $1}')"
|
||||
|
||||
Reference in New Issue
Block a user