schema: make source optional in volume XML

We don't parse it anyway.

https://bugzilla.redhat.com/show_bug.cgi?id=893273
This commit is contained in:
Ján Tomko 2013-05-16 15:43:06 +02:00
parent a07b88ee03
commit 25b98d31ec
4 changed files with 34 additions and 2 deletions

View File

@ -20,7 +20,9 @@
<text/>
</element>
</optional>
<ref name='source'/>
<optional>
<ref name='source'/>
</optional>
<ref name='sizing'/>
<ref name='target'/>
<optional>

View File

@ -78,6 +78,7 @@ EXTRA_DIST = \
storagepoolxml2xmlin \
storagepoolxml2xmlout \
storagevolxml2argvdata \
storagevolschemadata \
storagevolschematest \
storagevolxml2xmlin \
storagevolxml2xmlout \

View File

@ -0,0 +1,29 @@
<volume>
<name>OtherDemo.img</name>
<key>/var/lib/libvirt/images/OtherDemo.img</key>
<capacity unit="G">5</capacity>
<allocation>294912</allocation>
<target>
<path>/var/lib/libvirt/images/OtherDemo.img</path>
<format type='qcow2'/>
<permissions>
<mode>0644</mode>
<owner>0</owner>
<group>0</group>
<label>unconfined_u:object_r:virt_image_t:s0</label>
</permissions>
<encryption format='qcow'>
<secret type='passphrase' uuid='e78d4b51-a2af-485f-b0f5-afca709a80f4'/>
</encryption>
</target>
<backingStore>
<path>/dev/null</path>
<format type='raw'/>
<permissions>
<mode>0644</mode>
<owner>0</owner>
<group>0</group>
<label>unconfined_u:object_r:virt_image_t:s0</label>
</permissions>
</backingStore>
</volume>

View File

@ -4,7 +4,7 @@
. $srcdir/test-lib.sh
. $abs_srcdir/schematestutils.sh
DIRS="storagevolxml2xmlin storagevolxml2xmlout"
DIRS="storagevolxml2xmlin storagevolxml2xmlout storagevolschemadata"
SCHEMA="storagevol.rng"
check_schema "$DIRS" "$SCHEMA"