|
1 <?xml version="1.0" encoding="UTF-8"?><?xml-stylesheet href="test-to-html.xsl" type="text/xml"?> |
|
2 |
|
3 <!-- |
|
4 |
|
5 Copyright (c) 2001-2004 World Wide Web Consortium, |
|
6 (Massachusetts Institute of Technology, Institut National de |
|
7 Recherche en Informatique et en Automatique, Keio University). All |
|
8 Rights Reserved. This program is distributed under the W3C's Software |
|
9 Intellectual Property License. This program is distributed in the |
|
10 hope that it will be useful, but WITHOUT ANY WARRANTY; without even |
|
11 the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR |
|
12 PURPOSE. |
|
13 |
|
14 See W3C License http://www.w3.org/Consortium/Legal/ for more details. |
|
15 |
|
16 --> |
|
17 |
|
18 |
|
19 <test xmlns="http://www.w3.org/2001/DOM-Test-Suite/Level-3" name="splitcdatasections01"> |
|
20 <metadata> |
|
21 <title>splitcdatasections</title> |
|
22 <creator>Curt Arnold</creator> |
|
23 <description> |
|
24 Add a CDATASection containing "]]>" and call Node.normalize which should not |
|
25 split or raise warning. |
|
26 </description> |
|
27 <date qualifier="created">2004-02-25</date> |
|
28 <subject resource="http://www.w3.org/TR/2004/REC-DOM-Level-3-Core-20040407/core#ID-normalize"/> |
|
29 <subject resource="http://www.w3.org/TR/2004/REC-DOM-Level-3-Core-20040407/core#parameter-split-cdata-sections"/> |
|
30 </metadata> |
|
31 <var name="doc" type="Document"/> |
|
32 <var name="elem" type="Element"/> |
|
33 <var name="domConfig" type="DOMConfiguration"/> |
|
34 <var name="elemList" type="NodeList"/> |
|
35 <var name="newChild" type="CDATASection"/> |
|
36 <var name="oldChild" type="Node"/> |
|
37 <var name="retval" type="Node"/> |
|
38 <var name="errorMonitor" type="DOMErrorMonitor"/> |
|
39 <var name="errors" type="List"/> |
|
40 <load var="doc" href="barfoo" willBeModified="true"/> |
|
41 <getElementsByTagName var="elemList" obj="doc" tagname='"p"' interface="Document"/> |
|
42 <item var="elem" obj="elemList" index="0" interface="NodeList"/> |
|
43 <firstChild var="oldChild" obj="elem" interface="Node"/> |
|
44 <createCDATASection var="newChild" obj="doc" data='"this is not ]]> good"'/> |
|
45 <replaceChild var="retval" obj="elem" newChild="newChild" oldChild="oldChild"/> |
|
46 <domConfig obj="doc" var="domConfig" interface="Document"/> |
|
47 <setParameter obj="domConfig" name='"split-cdata-sections"' value="false"/> |
|
48 <setParameter obj="domConfig" name='"error-handler"' value="errorMonitor"/> |
|
49 <normalize obj="doc"/> |
|
50 <assertLowerSeverity obj="errorMonitor" severity="SEVERITY_ERROR" id="noErrors"/> |
|
51 </test> |
|
52 |