aboutsummaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorDaniel Veillard <veillard@src.gnome.org>2008-03-25 16:52:41 +0000
committerDaniel Veillard <veillard@src.gnome.org>2008-03-25 16:52:41 +0000
commit97c9ce2e991de1df49b326c7315b4e61fe6cfc2c (patch)
treea70f0ad8da8eb67a3f0ecbdc595dfbbe43a87dcd /test
parente54c3173b85d2d7eb90fb3b95d96dc761018c15b (diff)
downloadandroid_external_libxml2-97c9ce2e991de1df49b326c7315b4e61fe6cfc2c.tar.gz
android_external_libxml2-97c9ce2e991de1df49b326c7315b4e61fe6cfc2c.tar.bz2
android_external_libxml2-97c9ce2e991de1df49b326c7315b4e61fe6cfc2c.zip
fix various attribute normalisation problems reported by Ashwin this
* parser.c: fix various attribute normalisation problems reported by Ashwin * result/c14n/without-comments/example-4 result/c14n/with-comments/example-4: this impacted the result of two c14n tests :-\ * test/att9 test/att10 test/att11 result//att9* result//att10* result//att11*: added 3 specific regression tests coming from the XML spec revision and from Ashwin Daniel svn path=/trunk/; revision=3715
Diffstat (limited to 'test')
-rw-r--r--test/att1022
-rw-r--r--test/att1113
-rw-r--r--test/att95
3 files changed, 40 insertions, 0 deletions
diff --git a/test/att10 b/test/att10
new file mode 100644
index 00000000..5c14dc69
--- /dev/null
+++ b/test/att10
@@ -0,0 +1,22 @@
+<!DOCTYPE doc [
+<!ELEMENT doc (tst*)>
+<!ELEMENT tst (#PCDATA)>
+<!ATTLIST tst a NMTOKENS #IMPLIED>
+<!ATTLIST tst b CDATA #IMPLIED>
+<!ENTITY d "&#xD;">
+<!ENTITY a "&#xA;">
+<!ENTITY da "&#xD;&#xA;">
+]>
+<doc>
+<tst a="
+
+xyz" b="
+
+xyz"/>
+<tst a="&d;&d;A&a;&#x20;&a;B&da;" b="&d;&d;A&a;&#x20;&a;B&da;"/>
+<tst a="&#xd;&#xd;A&#xa;&#xa;B&#xd;&#xa;" b="&#xd;&#xd;A&#xa;&#xa;B&#xd;&#xa;"/>
+<tst a="&#32;x&#32;&#32;y&#32;" b="&#32;x&#32;&#32;y&#32;"/>
+<tst a=" a b " b=" a b "/>
+<tst a=" a b " b=" a b "/>
+</doc>
+
diff --git a/test/att11 b/test/att11
new file mode 100644
index 00000000..32faaf30
--- /dev/null
+++ b/test/att11
@@ -0,0 +1,13 @@
+<?xml version='1.0' standalone='yes'?>
+<!DOCTYPE attributes [
+<!ELEMENT attributes EMPTY>
+<!ATTLIST attributes
+ nmtoken NMTOKEN #IMPLIED
+ nmtokens NMTOKENS #IMPLIED>
+<!ENTITY ent " entity&recursive; ">
+<!ENTITY recursive "reference">
+]>
+<attributes
+ nmtoken = " &ent; &ent; &ent; "
+ nmtokens = " Test&#x0d;&#x0a; this&#x20; normalization "
+/>
diff --git a/test/att9 b/test/att9
new file mode 100644
index 00000000..f06b531a
--- /dev/null
+++ b/test/att9
@@ -0,0 +1,5 @@
+<!DOCTYPE doc [
+<!ATTLIST doc a1 NMTOKENS " 1 2 ">
+<!ELEMENT doc (#PCDATA)>
+]>
+<doc/>