mirror of
https://github.com/libvirt/libvirt.git
synced 2025-02-25 18:55:26 -06:00
schema: fix idmap validation
When idmap was added to LXC, we forgot to cover it in the testsuite. The schema was missing an <element> layer, and as a result, virt-xml-validate was failing on valid dumpxml output. Reported by Eduard - Gabriel Munteanu on IRC. * docs/schemas/domaincommon.rng (idmap): Include <idmap> element, and support interleaves. * tests/lxcxml2xmldata/lxc-idmap.xml: New file. * tests/lxcxml2xmltest.c (mymain): Test it. Signed-off-by: Eric Blake <eblake@redhat.com>
This commit is contained in:
@@ -506,32 +506,38 @@
|
||||
</interleave>
|
||||
</define>
|
||||
<define name="idmap">
|
||||
<zeroOrMore>
|
||||
<element name="uid">
|
||||
<attribute name="start">
|
||||
<ref name="unsignedInt"/>
|
||||
</attribute>
|
||||
<attribute name="target">
|
||||
<ref name="unsignedInt"/>
|
||||
</attribute>
|
||||
<attribute name="count">
|
||||
<ref name="unsignedInt"/>
|
||||
</attribute>
|
||||
</element>
|
||||
</zeroOrMore>
|
||||
<zeroOrMore>
|
||||
<element name="gid">
|
||||
<attribute name="start">
|
||||
<ref name="unsignedInt"/>
|
||||
</attribute>
|
||||
<attribute name="target">
|
||||
<ref name="unsignedInt"/>
|
||||
</attribute>
|
||||
<attribute name="count">
|
||||
<ref name="unsignedInt"/>
|
||||
</attribute>
|
||||
</element>
|
||||
</zeroOrMore>
|
||||
<element name="idmap">
|
||||
<interleave>
|
||||
<zeroOrMore>
|
||||
<element name="uid">
|
||||
<attribute name="start">
|
||||
<ref name="unsignedInt"/>
|
||||
</attribute>
|
||||
<attribute name="target">
|
||||
<ref name="unsignedInt"/>
|
||||
</attribute>
|
||||
<attribute name="count">
|
||||
<ref name="unsignedInt"/>
|
||||
</attribute>
|
||||
<empty/>
|
||||
</element>
|
||||
</zeroOrMore>
|
||||
<zeroOrMore>
|
||||
<element name="gid">
|
||||
<attribute name="start">
|
||||
<ref name="unsignedInt"/>
|
||||
</attribute>
|
||||
<attribute name="target">
|
||||
<ref name="unsignedInt"/>
|
||||
</attribute>
|
||||
<attribute name="count">
|
||||
<ref name="unsignedInt"/>
|
||||
</attribute>
|
||||
<empty/>
|
||||
</element>
|
||||
</zeroOrMore>
|
||||
</interleave>
|
||||
</element>
|
||||
</define>
|
||||
<!--
|
||||
Resources usage defines the amount of memory (maximum and possibly
|
||||
|
||||
Reference in New Issue
Block a user