When using xmllint --schema to run test case of libxml2 , test result is different from make check
-
I have a little confusion. When I use xmllint to run test cases of libxml2 source code, there is a test result that is different from make check.
-
running result of
xmllint --schema test/schemas/any4_0.xsd test/schemas/any4_0.xml
is ERROR.
test/schemas/any4_0.xsd:14: element complexType: Schemas parser error : local complex type: The content model is not determinist.
- running result of
make check
is OK.
$ cat result/schemas/any4_0_0.err
$ cat result/schemas/any4_0_0
./test/schemas/any4_0.xml validates
- test/schemas/any4_0.xsd
<?xml version="1.0"?>
<xsd:schema
xmlns:xsd="http://www.w3.org/2001/XMLSchema"
targetNamespace="http://FOO"
xmlns:foo="http://FOO">
<xsd:element name="boo">
<xsd:complexType>
<xsd:attribute name="booAttr" type="xsd:integer" />
</xsd:complexType>
</xsd:element>
<xsd:element name="foo">
<xsd:complexType>
<xsd:choice>
<xsd:any namespace="http://FOO" processContents="lax" maxOccurs="1"/>
<xsd:element name="anything" form="qualified">
<xsd:complexType>
<xsd:sequence>
<xsd:element ref="foo:boo"/>
</xsd:sequence>
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
- test/schemas/any4_0.xml
<?xml version="1.0" encoding="ISO-8859-1"?>
<!-- Tests xsd:any.
invalid: <bar.A/> and <foo:bar.B/>
valid: <bar:bar.C/>
-->
<foo:foo
xmlns:foo="http://FOO"
xmlns:bar="http://BAR"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://FOO any4_0.xsd">
<foo:anything>
<foo:boo booAttr="123"/>
</foo:anything>
</foo:foo>
- version:
$xmllint --version
xmllint: using libxml version 20909
compiled with: Threads Tree Output Push Reader Patterns Writer SAXv1 FTP HTTP DTDValid HTML Legacy C14N Catalog XPath XPointer XInclude Iconv ISO8859X Unicode Regexps Automata Expr Schemas Schematron Modules Debug Zlib Lzma