]> xenbits.xensource.com Git - people/liuw/libxenctrl-split/libvirt.git/commitdiff
tests: Update read-bufsiz to delete the UUID of vm XML
authorOsier Yang <jyang@redhat.com>
Tue, 17 Apr 2012 14:56:18 +0000 (22:56 +0800)
committerOsier Yang <jyang@redhat.com>
Tue, 17 Apr 2012 14:56:18 +0000 (22:56 +0800)
Since now we have fixed domain UUID for test driver, defining
a domain with different name but same UUID doesn't work any
more. This patch delete the UUID from the dumped XML so that
it could be generated.

tests/read-bufsiz

index 2a91bcf5b25dcd0e90f85b08d710a7ba2bfb267e..a4c6007653e7fc7fd997e56a2d73625d572aeb2b 100755 (executable)
@@ -32,8 +32,10 @@ fail=0
 # Output a valid definition, to be used as input.
 $abs_top_builddir/tools/virsh -c test:///default dumpxml 1 > xml.t || fail=1
 
-# Change the VM name
-sed -e "s|<name>test</name>|<name>newtest</name>|g" xml.t > xml
+# Change the VM name and UUID
+sed -e "s|<name>test</name>|<name>newtest</name>|g" \
+  -e "\|<uuid>.*</uuid>|d" \
+  xml.t > xml
 
 for i in before after; do
   # The largest BUFSIZ I've seen is 128K.  This is slightly larger.