Commit 21edf9b4 authored by Kasimier T. Buchcik's avatar Kasimier T. Buchcik

Added regression tests (from Dhyanesh).

* test/schemas/empty-value* result/schemas/empty-value*:
  Added regression tests (from Dhyanesh).
parent 9c215eb3
Tue Jun 21 10:44:34 CEST 2005 Kasimier Buchcik <libxml2-cvs@cazic.net>
* test/schemas/empty-value* result/schemas/empty-value*:
Added regression tests (from Dhyanesh).
Tue Jun 21 10:35:43 CEST 2005 Kasimier Buchcik <libxml2-cvs@cazic.net>
* xmlschemas.c: Fixed NULL values to be validated as empty
......
./test/schemas/empty-value_0.xml validates
./test/schemas/empty-value_1.xml validates
<?xml version="1.0" encoding="UTF-8"?>
<element1/>
<?xml version="1.0" encoding="UTF-8"?>
<element2 att="test"/>
<?xml version="1.0"?>
<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema"
elementFormDefault="qualified"
attributeFormDefault="unqualified">
<xs:simpleType name="myDouble">
<xs:union memberTypes="xs:double">
<xs:simpleType>
<xs:restriction base="xs:string">
<xs:pattern value="\s*(N/A)?\s*"/>
</xs:restriction>
</xs:simpleType>
</xs:union>
</xs:simpleType>
<xs:element name="element1" type="myDouble"/>
<xs:element name="element2">
<xs:complexType>
<xs:simpleContent>
<xs:extension base="myDouble">
<xs:attribute name="att" type="xs:string"/>
</xs:extension>
</xs:simpleContent>
</xs:complexType>
</xs:element>
</xs:schema>
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment