[PATCH 20/24] storagevolxml2argvtest: Use internal wrapping of command line arguments

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



virCommandToString has the possibility to return an already wrapped
string with better format than what we get from the test wrapper script.

Signed-off-by: Peter Krempa <pkrempa@xxxxxxxxxx>
---
 tests/storagevolxml2argvdata/iso-input.argv        |  4 +++-
 tests/storagevolxml2argvdata/iso.argv              |  4 +++-
 .../storagevolxml2argvdata/logical-from-qcow2.argv |  4 +++-
 tests/storagevolxml2argvdata/luks-cipher.argv      |  6 +++---
 .../luks-convert-encrypt.argv                      | 12 +++++-------
 .../luks-convert-encrypt2fileqcow2.argv            | 12 ++++++------
 .../luks-convert-encrypt2fileraw.argv              | 12 ++++++------
 .../storagevolxml2argvdata/luks-convert-qcow2.argv | 11 +++++------
 tests/storagevolxml2argvdata/luks-convert.argv     | 10 +++++-----
 tests/storagevolxml2argvdata/luks.argv             |  3 ++-
 tests/storagevolxml2argvdata/qcow2-1.1.argv        |  4 +++-
 tests/storagevolxml2argvdata/qcow2-compat.argv     |  4 +++-
 .../qcow2-from-logical-compat.argv                 |  4 +++-
 tests/storagevolxml2argvdata/qcow2-lazy.argv       |  5 +++--
 .../qcow2-luks-convert-encrypt.argv                | 14 ++++++--------
 .../qcow2-luks-convert-encrypt2fileqcow2.argv      | 12 ++++++------
 .../qcow2-luks-convert-encrypt2fileraw.argv        | 12 ++++++------
 tests/storagevolxml2argvdata/qcow2-luks.argv       |  6 +++---
 .../qcow2-nobacking-convert-prealloc-compat.argv   |  4 ++--
 .../qcow2-nobacking-prealloc-compat.argv           |  5 +++--
 .../qcow2-nocapacity-convert-prealloc.argv         |  4 ++--
 tests/storagevolxml2argvdata/qcow2-nocapacity.argv |  3 ++-
 .../storagevolxml2argvdata/qcow2-nocow-compat.argv |  5 +++--
 .../storagevolxml2argvdata/qcow2-zerocapacity.argv |  4 +++-
 tests/storagevolxml2argvtest.c                     |  6 +++---
 25 files changed, 92 insertions(+), 78 deletions(-)

diff --git a/tests/storagevolxml2argvdata/iso-input.argv b/tests/storagevolxml2argvdata/iso-input.argv
index 203f27ca22..16e0e91a4c 100644
--- a/tests/storagevolxml2argvdata/iso-input.argv
+++ b/tests/storagevolxml2argvdata/iso-input.argv
@@ -1,4 +1,6 @@
 qemu-img \
 convert \
 -f raw \
--O raw /var/lib/libvirt/images/test.iso /var/lib/libvirt/images/sparse.img
+-O raw \
+/var/lib/libvirt/images/test.iso \
+/var/lib/libvirt/images/sparse.img
diff --git a/tests/storagevolxml2argvdata/iso.argv b/tests/storagevolxml2argvdata/iso.argv
index f74505ecec..52b29a51c2 100644
--- a/tests/storagevolxml2argvdata/iso.argv
+++ b/tests/storagevolxml2argvdata/iso.argv
@@ -1,3 +1,5 @@
 qemu-img \
 create \
--f raw /var/lib/libvirt/images/test.iso 1024K
+-f raw \
+/var/lib/libvirt/images/test.iso \
+1024K
diff --git a/tests/storagevolxml2argvdata/logical-from-qcow2.argv b/tests/storagevolxml2argvdata/logical-from-qcow2.argv
index c1b3cef4b9..3da4dada9b 100644
--- a/tests/storagevolxml2argvdata/logical-from-qcow2.argv
+++ b/tests/storagevolxml2argvdata/logical-from-qcow2.argv
@@ -1,4 +1,6 @@
 qemu-img \
 convert \
 -f qcow2 \
--O raw /var/lib/libvirt/images/OtherDemo.img /dev/HostVG/Swap
+-O raw \
+/var/lib/libvirt/images/OtherDemo.img \
+/dev/HostVG/Swap
diff --git a/tests/storagevolxml2argvdata/luks-cipher.argv b/tests/storagevolxml2argvdata/luks-cipher.argv
index bb4438949c..f482018182 100644
--- a/tests/storagevolxml2argvdata/luks-cipher.argv
+++ b/tests/storagevolxml2argvdata/luks-cipher.argv
@@ -2,6 +2,6 @@ qemu-img \
 create \
 -f luks \
 --object secret,id=LuksDemo.img_encrypt0,file=/path/to/secretFile \
--o key-secret=LuksDemo.img_encrypt0,cipher-alg=serpent-256,cipher-mode=cbc,\
-hash-alg=sha256,ivgen-alg=plain64,\
-ivgen-hash-alg=sha256 /var/lib/libvirt/images/LuksDemo.img 5242880K
+-o key-secret=LuksDemo.img_encrypt0,cipher-alg=serpent-256,cipher-mode=cbc,hash-alg=sha256,ivgen-alg=plain64,ivgen-hash-alg=sha256 \
+/var/lib/libvirt/images/LuksDemo.img \
+5242880K
diff --git a/tests/storagevolxml2argvdata/luks-convert-encrypt.argv b/tests/storagevolxml2argvdata/luks-convert-encrypt.argv
index 456ae621d1..307e08c9b4 100644
--- a/tests/storagevolxml2argvdata/luks-convert-encrypt.argv
+++ b/tests/storagevolxml2argvdata/luks-convert-encrypt.argv
@@ -2,7 +2,8 @@ qemu-img \
 create \
 -f luks \
 --object secret,id=LuksDemo.img_encrypt0,file=/path/to/secretFile \
--o key-secret=LuksDemo.img_encrypt0 /var/lib/libvirt/images/LuksDemo.img \
+-o key-secret=LuksDemo.img_encrypt0 \
+/var/lib/libvirt/images/LuksDemo.img \
 5242880K
 qemu-img \
 convert \
@@ -10,9 +11,6 @@ convert \
 -n \
 --target-image-opts \
 --object secret,id=LuksDemo.img_encrypt0,file=/path/to/secretFile \
---object secret,id=OtherDemo.img_encrypt0,\
-file=/path/to/inputSecretFile driver=luks,\
-file.filename=/var/lib/libvirt/images/OtherDemo.img,\
-key-secret=OtherDemo.img_encrypt0 driver=luks,\
-file.filename=/var/lib/libvirt/images/LuksDemo.img,\
-key-secret=LuksDemo.img_encrypt0
+--object secret,id=OtherDemo.img_encrypt0,file=/path/to/inputSecretFile \
+driver=luks,file.filename=/var/lib/libvirt/images/OtherDemo.img,key-secret=OtherDemo.img_encrypt0 \
+driver=luks,file.filename=/var/lib/libvirt/images/LuksDemo.img,key-secret=LuksDemo.img_encrypt0
diff --git a/tests/storagevolxml2argvdata/luks-convert-encrypt2fileqcow2.argv b/tests/storagevolxml2argvdata/luks-convert-encrypt2fileqcow2.argv
index 1320e2ee2f..4b9ccfe8dc 100644
--- a/tests/storagevolxml2argvdata/luks-convert-encrypt2fileqcow2.argv
+++ b/tests/storagevolxml2argvdata/luks-convert-encrypt2fileqcow2.argv
@@ -1,14 +1,14 @@
 qemu-img \
 create \
 -f qcow2 \
--o compat=0.10 /var/lib/libvirt/images/sparse-qcow2.img 1073741824K
+-o compat=0.10 \
+/var/lib/libvirt/images/sparse-qcow2.img \
+1073741824K
 qemu-img \
 convert \
 --image-opts \
 -n \
 --target-image-opts \
---object secret,id=OtherDemo.img_encrypt0,\
-file=/path/to/inputSecretFile driver=luks,\
-file.filename=/var/lib/libvirt/images/OtherDemo.img,\
-key-secret=OtherDemo.img_encrypt0 driver=qcow2,\
-file.filename=/var/lib/libvirt/images/sparse-qcow2.img
+--object secret,id=OtherDemo.img_encrypt0,file=/path/to/inputSecretFile \
+driver=luks,file.filename=/var/lib/libvirt/images/OtherDemo.img,key-secret=OtherDemo.img_encrypt0 \
+driver=qcow2,file.filename=/var/lib/libvirt/images/sparse-qcow2.img
diff --git a/tests/storagevolxml2argvdata/luks-convert-encrypt2fileraw.argv b/tests/storagevolxml2argvdata/luks-convert-encrypt2fileraw.argv
index e140850217..d48dbf371c 100644
--- a/tests/storagevolxml2argvdata/luks-convert-encrypt2fileraw.argv
+++ b/tests/storagevolxml2argvdata/luks-convert-encrypt2fileraw.argv
@@ -1,13 +1,13 @@
 qemu-img \
 create \
--f raw /var/lib/libvirt/images/sparse.img 1073741824K
+-f raw \
+/var/lib/libvirt/images/sparse.img \
+1073741824K
 qemu-img \
 convert \
 --image-opts \
 -n \
 --target-image-opts \
---object secret,id=OtherDemo.img_encrypt0,\
-file=/path/to/inputSecretFile driver=luks,\
-file.filename=/var/lib/libvirt/images/OtherDemo.img,\
-key-secret=OtherDemo.img_encrypt0 driver=raw,\
-file.filename=/var/lib/libvirt/images/sparse.img
+--object secret,id=OtherDemo.img_encrypt0,file=/path/to/inputSecretFile \
+driver=luks,file.filename=/var/lib/libvirt/images/OtherDemo.img,key-secret=OtherDemo.img_encrypt0 \
+driver=raw,file.filename=/var/lib/libvirt/images/sparse.img
diff --git a/tests/storagevolxml2argvdata/luks-convert-qcow2.argv b/tests/storagevolxml2argvdata/luks-convert-qcow2.argv
index 78cd9a2a8d..050d6fce0d 100644
--- a/tests/storagevolxml2argvdata/luks-convert-qcow2.argv
+++ b/tests/storagevolxml2argvdata/luks-convert-qcow2.argv
@@ -2,15 +2,14 @@ qemu-img \
 create \
 -f luks \
 --object secret,id=OtherDemo.img_encrypt0,file=/path/to/secretFile \
--o key-secret=OtherDemo.img_encrypt0 /var/lib/libvirt/images/OtherDemo.img \
+-o key-secret=OtherDemo.img_encrypt0 \
+/var/lib/libvirt/images/OtherDemo.img \
 5242880K
 qemu-img \
 convert \
 --image-opts \
 -n \
 --target-image-opts \
---object secret,id=OtherDemo.img_encrypt0,\
-file=/path/to/secretFile driver=qcow2,\
-file.filename=/var/lib/libvirt/images/sparse-qcow2.img driver=luks,\
-file.filename=/var/lib/libvirt/images/OtherDemo.img,\
-key-secret=OtherDemo.img_encrypt0
+--object secret,id=OtherDemo.img_encrypt0,file=/path/to/secretFile \
+driver=qcow2,file.filename=/var/lib/libvirt/images/sparse-qcow2.img \
+driver=luks,file.filename=/var/lib/libvirt/images/OtherDemo.img,key-secret=OtherDemo.img_encrypt0
diff --git a/tests/storagevolxml2argvdata/luks-convert.argv b/tests/storagevolxml2argvdata/luks-convert.argv
index e4a8277d7f..5b6bc7bc63 100644
--- a/tests/storagevolxml2argvdata/luks-convert.argv
+++ b/tests/storagevolxml2argvdata/luks-convert.argv
@@ -2,14 +2,14 @@ qemu-img \
 create \
 -f luks \
 --object secret,id=OtherDemo.img_encrypt0,file=/path/to/secretFile \
--o key-secret=OtherDemo.img_encrypt0 /var/lib/libvirt/images/OtherDemo.img \
+-o key-secret=OtherDemo.img_encrypt0 \
+/var/lib/libvirt/images/OtherDemo.img \
 5242880K
 qemu-img \
 convert \
 --image-opts \
 -n \
 --target-image-opts \
---object secret,id=OtherDemo.img_encrypt0,file=/path/to/secretFile driver=raw,\
-file.filename=/var/lib/libvirt/images/sparse.img driver=luks,\
-file.filename=/var/lib/libvirt/images/OtherDemo.img,\
-key-secret=OtherDemo.img_encrypt0
+--object secret,id=OtherDemo.img_encrypt0,file=/path/to/secretFile \
+driver=raw,file.filename=/var/lib/libvirt/images/sparse.img \
+driver=luks,file.filename=/var/lib/libvirt/images/OtherDemo.img,key-secret=OtherDemo.img_encrypt0
diff --git a/tests/storagevolxml2argvdata/luks.argv b/tests/storagevolxml2argvdata/luks.argv
index 5013c8ca7f..41b5fd663c 100644
--- a/tests/storagevolxml2argvdata/luks.argv
+++ b/tests/storagevolxml2argvdata/luks.argv
@@ -2,5 +2,6 @@ qemu-img \
 create \
 -f luks \
 --object secret,id=LuksDemo.img_encrypt0,file=/path/to/secretFile \
--o key-secret=LuksDemo.img_encrypt0 /var/lib/libvirt/images/LuksDemo.img \
+-o key-secret=LuksDemo.img_encrypt0 \
+/var/lib/libvirt/images/LuksDemo.img \
 5242880K
diff --git a/tests/storagevolxml2argvdata/qcow2-1.1.argv b/tests/storagevolxml2argvdata/qcow2-1.1.argv
index 5ee974afe9..40fbe065e0 100644
--- a/tests/storagevolxml2argvdata/qcow2-1.1.argv
+++ b/tests/storagevolxml2argvdata/qcow2-1.1.argv
@@ -2,4 +2,6 @@ qemu-img \
 create \
 -f qcow2 \
 -b /dev/null \
--o backing_fmt=raw,compat=1.1 /var/lib/libvirt/images/OtherDemo.img 5242880K
+-o backing_fmt=raw,compat=1.1 \
+/var/lib/libvirt/images/OtherDemo.img \
+5242880K
diff --git a/tests/storagevolxml2argvdata/qcow2-compat.argv b/tests/storagevolxml2argvdata/qcow2-compat.argv
index 3071d7a790..bf3a50a7f3 100644
--- a/tests/storagevolxml2argvdata/qcow2-compat.argv
+++ b/tests/storagevolxml2argvdata/qcow2-compat.argv
@@ -2,4 +2,6 @@ qemu-img \
 create \
 -f qcow2 \
 -b /dev/null \
--o backing_fmt=raw,compat=0.10 /var/lib/libvirt/images/OtherDemo.img 5242880K
+-o backing_fmt=raw,compat=0.10 \
+/var/lib/libvirt/images/OtherDemo.img \
+5242880K
diff --git a/tests/storagevolxml2argvdata/qcow2-from-logical-compat.argv b/tests/storagevolxml2argvdata/qcow2-from-logical-compat.argv
index 1971da200d..dbc7deb16a 100644
--- a/tests/storagevolxml2argvdata/qcow2-from-logical-compat.argv
+++ b/tests/storagevolxml2argvdata/qcow2-from-logical-compat.argv
@@ -2,4 +2,6 @@ qemu-img \
 convert \
 -f raw \
 -O qcow2 \
--o compat=0.10 /dev/HostVG/Swap /var/lib/libvirt/images/OtherDemo.img
+-o compat=0.10 \
+/dev/HostVG/Swap \
+/var/lib/libvirt/images/OtherDemo.img
diff --git a/tests/storagevolxml2argvdata/qcow2-lazy.argv b/tests/storagevolxml2argvdata/qcow2-lazy.argv
index 2621b01168..cd551be6e9 100644
--- a/tests/storagevolxml2argvdata/qcow2-lazy.argv
+++ b/tests/storagevolxml2argvdata/qcow2-lazy.argv
@@ -2,5 +2,6 @@ qemu-img \
 create \
 -f qcow2 \
 -b /dev/null \
--o backing_fmt=raw,compat=1.1,\
-lazy_refcounts /var/lib/libvirt/images/OtherDemo.img 5242880K
+-o backing_fmt=raw,compat=1.1,lazy_refcounts \
+/var/lib/libvirt/images/OtherDemo.img \
+5242880K
diff --git a/tests/storagevolxml2argvdata/qcow2-luks-convert-encrypt.argv b/tests/storagevolxml2argvdata/qcow2-luks-convert-encrypt.argv
index de8aef4233..d89622d4a6 100644
--- a/tests/storagevolxml2argvdata/qcow2-luks-convert-encrypt.argv
+++ b/tests/storagevolxml2argvdata/qcow2-luks-convert-encrypt.argv
@@ -2,17 +2,15 @@ qemu-img \
 create \
 -f qcow2 \
 --object secret,id=OtherDemoLuks.img_encrypt0,file=/path/to/secretFile \
--o encrypt.format=luks,encrypt.key-secret=OtherDemoLuks.img_encrypt0,\
-compat=0.10 /var/lib/libvirt/images/OtherDemoLuks.img 5242880K
+-o encrypt.format=luks,encrypt.key-secret=OtherDemoLuks.img_encrypt0,compat=0.10 \
+/var/lib/libvirt/images/OtherDemoLuks.img \
+5242880K
 qemu-img \
 convert \
 --image-opts \
 -n \
 --target-image-opts \
 --object secret,id=OtherDemoLuks.img_encrypt0,file=/path/to/secretFile \
---object secret,id=OtherDemoLuksConvert.img_encrypt0,\
-file=/path/to/inputSecretFile driver=qcow2,\
-file.filename=/var/lib/libvirt/images/OtherDemoLuksConvert.img,\
-encrypt.key-secret=OtherDemoLuksConvert.img_encrypt0 driver=qcow2,\
-file.filename=/var/lib/libvirt/images/OtherDemoLuks.img,\
-encrypt.key-secret=OtherDemoLuks.img_encrypt0
+--object secret,id=OtherDemoLuksConvert.img_encrypt0,file=/path/to/inputSecretFile \
+driver=qcow2,file.filename=/var/lib/libvirt/images/OtherDemoLuksConvert.img,encrypt.key-secret=OtherDemoLuksConvert.img_encrypt0 \
+driver=qcow2,file.filename=/var/lib/libvirt/images/OtherDemoLuks.img,encrypt.key-secret=OtherDemoLuks.img_encrypt0
diff --git a/tests/storagevolxml2argvdata/qcow2-luks-convert-encrypt2fileqcow2.argv b/tests/storagevolxml2argvdata/qcow2-luks-convert-encrypt2fileqcow2.argv
index 517156ca83..4d910552d0 100644
--- a/tests/storagevolxml2argvdata/qcow2-luks-convert-encrypt2fileqcow2.argv
+++ b/tests/storagevolxml2argvdata/qcow2-luks-convert-encrypt2fileqcow2.argv
@@ -1,14 +1,14 @@
 qemu-img \
 create \
 -f qcow2 \
--o compat=0.10 /var/lib/libvirt/images/sparse-qcow2.img 1073741824K
+-o compat=0.10 \
+/var/lib/libvirt/images/sparse-qcow2.img \
+1073741824K
 qemu-img \
 convert \
 --image-opts \
 -n \
 --target-image-opts \
---object secret,id=OtherDemoLuksConvert.img_encrypt0,\
-file=/path/to/inputSecretFile driver=qcow2,\
-file.filename=/var/lib/libvirt/images/OtherDemoLuksConvert.img,\
-encrypt.key-secret=OtherDemoLuksConvert.img_encrypt0 driver=qcow2,\
-file.filename=/var/lib/libvirt/images/sparse-qcow2.img
+--object secret,id=OtherDemoLuksConvert.img_encrypt0,file=/path/to/inputSecretFile \
+driver=qcow2,file.filename=/var/lib/libvirt/images/OtherDemoLuksConvert.img,encrypt.key-secret=OtherDemoLuksConvert.img_encrypt0 \
+driver=qcow2,file.filename=/var/lib/libvirt/images/sparse-qcow2.img
diff --git a/tests/storagevolxml2argvdata/qcow2-luks-convert-encrypt2fileraw.argv b/tests/storagevolxml2argvdata/qcow2-luks-convert-encrypt2fileraw.argv
index 7483c864c1..24197bfd64 100644
--- a/tests/storagevolxml2argvdata/qcow2-luks-convert-encrypt2fileraw.argv
+++ b/tests/storagevolxml2argvdata/qcow2-luks-convert-encrypt2fileraw.argv
@@ -1,13 +1,13 @@
 qemu-img \
 create \
--f raw /var/lib/libvirt/images/sparse.img 1073741824K
+-f raw \
+/var/lib/libvirt/images/sparse.img \
+1073741824K
 qemu-img \
 convert \
 --image-opts \
 -n \
 --target-image-opts \
---object secret,id=OtherDemoLuksConvert.img_encrypt0,\
-file=/path/to/inputSecretFile driver=qcow2,\
-file.filename=/var/lib/libvirt/images/OtherDemoLuksConvert.img,\
-encrypt.key-secret=OtherDemoLuksConvert.img_encrypt0 driver=raw,\
-file.filename=/var/lib/libvirt/images/sparse.img
+--object secret,id=OtherDemoLuksConvert.img_encrypt0,file=/path/to/inputSecretFile \
+driver=qcow2,file.filename=/var/lib/libvirt/images/OtherDemoLuksConvert.img,encrypt.key-secret=OtherDemoLuksConvert.img_encrypt0 \
+driver=raw,file.filename=/var/lib/libvirt/images/sparse.img
diff --git a/tests/storagevolxml2argvdata/qcow2-luks.argv b/tests/storagevolxml2argvdata/qcow2-luks.argv
index 4b51b374ca..308316c90c 100644
--- a/tests/storagevolxml2argvdata/qcow2-luks.argv
+++ b/tests/storagevolxml2argvdata/qcow2-luks.argv
@@ -3,6 +3,6 @@ create \
 -f qcow2 \
 -b /dev/null \
 --object secret,id=OtherDemoLuks.img_encrypt0,file=/path/to/secretFile \
--o backing_fmt=raw,encrypt.format=luks,\
-encrypt.key-secret=OtherDemoLuks.img_encrypt0,\
-compat=0.10 /var/lib/libvirt/images/OtherDemoLuks.img 5242880K
+-o backing_fmt=raw,encrypt.format=luks,encrypt.key-secret=OtherDemoLuks.img_encrypt0,compat=0.10 \
+/var/lib/libvirt/images/OtherDemoLuks.img \
+5242880K
diff --git a/tests/storagevolxml2argvdata/qcow2-nobacking-convert-prealloc-compat.argv b/tests/storagevolxml2argvdata/qcow2-nobacking-convert-prealloc-compat.argv
index 87489641d5..463ae26779 100644
--- a/tests/storagevolxml2argvdata/qcow2-nobacking-convert-prealloc-compat.argv
+++ b/tests/storagevolxml2argvdata/qcow2-nobacking-convert-prealloc-compat.argv
@@ -2,6 +2,6 @@ qemu-img \
 convert \
 -f raw \
 -O qcow2 \
--o preallocation=metadata,\
-compat=0.10 /var/lib/libvirt/images/sparse.img \
+-o preallocation=metadata,compat=0.10 \
+/var/lib/libvirt/images/sparse.img \
 /var/lib/libvirt/images/OtherDemo.img
diff --git a/tests/storagevolxml2argvdata/qcow2-nobacking-prealloc-compat.argv b/tests/storagevolxml2argvdata/qcow2-nobacking-prealloc-compat.argv
index a883030744..510e0c13f6 100644
--- a/tests/storagevolxml2argvdata/qcow2-nobacking-prealloc-compat.argv
+++ b/tests/storagevolxml2argvdata/qcow2-nobacking-prealloc-compat.argv
@@ -1,5 +1,6 @@
 qemu-img \
 create \
 -f qcow2 \
--o preallocation=metadata,\
-compat=0.10 /var/lib/libvirt/images/OtherDemo.img 5242880K
+-o preallocation=metadata,compat=0.10 \
+/var/lib/libvirt/images/OtherDemo.img \
+5242880K
diff --git a/tests/storagevolxml2argvdata/qcow2-nocapacity-convert-prealloc.argv b/tests/storagevolxml2argvdata/qcow2-nocapacity-convert-prealloc.argv
index 049d2d73b5..0152b1efb6 100644
--- a/tests/storagevolxml2argvdata/qcow2-nocapacity-convert-prealloc.argv
+++ b/tests/storagevolxml2argvdata/qcow2-nocapacity-convert-prealloc.argv
@@ -2,6 +2,6 @@ qemu-img \
 convert \
 -f raw \
 -O qcow2 \
--o preallocation=falloc,\
-compat=0.10 /var/lib/libvirt/images/sparse.img \
+-o preallocation=falloc,compat=0.10 \
+/var/lib/libvirt/images/sparse.img \
 /var/lib/libvirt/images/OtherDemo.img
diff --git a/tests/storagevolxml2argvdata/qcow2-nocapacity.argv b/tests/storagevolxml2argvdata/qcow2-nocapacity.argv
index 30bcfb00c7..047932a559 100644
--- a/tests/storagevolxml2argvdata/qcow2-nocapacity.argv
+++ b/tests/storagevolxml2argvdata/qcow2-nocapacity.argv
@@ -2,4 +2,5 @@ qemu-img \
 create \
 -f qcow2 \
 -b /dev/null \
--o backing_fmt=raw,compat=0.10 /var/lib/libvirt/images/OtherDemo.img
+-o backing_fmt=raw,compat=0.10 \
+/var/lib/libvirt/images/OtherDemo.img
diff --git a/tests/storagevolxml2argvdata/qcow2-nocow-compat.argv b/tests/storagevolxml2argvdata/qcow2-nocow-compat.argv
index 5e327dab0b..4cc7904cfc 100644
--- a/tests/storagevolxml2argvdata/qcow2-nocow-compat.argv
+++ b/tests/storagevolxml2argvdata/qcow2-nocow-compat.argv
@@ -2,5 +2,6 @@ qemu-img \
 create \
 -f qcow2 \
 -b /dev/null \
--o backing_fmt=raw,nocow=on,\
-compat=0.10 /var/lib/libvirt/images/OtherDemo.img 5242880K
+-o backing_fmt=raw,nocow=on,compat=0.10 \
+/var/lib/libvirt/images/OtherDemo.img \
+5242880K
diff --git a/tests/storagevolxml2argvdata/qcow2-zerocapacity.argv b/tests/storagevolxml2argvdata/qcow2-zerocapacity.argv
index 95dfc65d9b..607c642e6f 100644
--- a/tests/storagevolxml2argvdata/qcow2-zerocapacity.argv
+++ b/tests/storagevolxml2argvdata/qcow2-zerocapacity.argv
@@ -1,4 +1,6 @@
 qemu-img \
 create \
 -f qcow2 \
--o compat=0.10 /var/lib/libvirt/images/OtherDemo.img 0K
+-o compat=0.10 \
+/var/lib/libvirt/images/OtherDemo.img \
+0K
diff --git a/tests/storagevolxml2argvtest.c b/tests/storagevolxml2argvtest.c
index 5e62313441..1b639e157e 100644
--- a/tests/storagevolxml2argvtest.c
+++ b/tests/storagevolxml2argvtest.c
@@ -104,13 +104,13 @@ testCompareXMLToArgvFiles(bool shouldFail,
         }

         if (convertStep != VIR_STORAGE_VOL_ENCRYPT_CONVERT) {
-            if (!(actualCmdline = virCommandToString(cmd, false)))
+            if (!(actualCmdline = virCommandToString(cmd, true)))
                 goto cleanup;
         } else {
             char *createCmdline = actualCmdline;
             g_autofree char *cvtCmdline = NULL;

-            if (!(cvtCmdline = virCommandToString(cmd, false)))
+            if (!(cvtCmdline = virCommandToString(cmd, true)))
                 goto cleanup;

             actualCmdline = g_strdup_printf("%s\n%s", createCmdline, cvtCmdline);
@@ -127,7 +127,7 @@ testCompareXMLToArgvFiles(bool shouldFail,

     } while (convertStep != VIR_STORAGE_VOL_ENCRYPT_DONE);

-    if (virTestCompareToFile(actualCmdline, cmdline) < 0)
+    if (virTestCompareToFileFull(actualCmdline, cmdline, false) < 0)
         goto cleanup;

     ret = 0;
-- 
2.30.2




[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]

  Powered by Linux