Subversion Repositories Kolibri OS

Rev

Go to most recent revision | Blame | Last modification | View Log | Download | RSS feed

  1. <?xml version="1.0" encoding="UTF-8"?>
  2. <!--
  3. Copyright (c) 2001 World Wide Web Consortium,
  4. (Massachusetts Institute of Technology, Institut National de
  5. Recherche en Informatique et en Automatique, Keio University). All
  6. Rights Reserved. This program is distributed under the W3C's Software
  7. Intellectual Property License. This program is distributed in the
  8. hope that it will be useful, but WITHOUT ANY WARRANTY; without even
  9. the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
  10. PURPOSE.
  11. See W3C License http://www.w3.org/Consortium/Legal/ for more details.
  12. --><!DOCTYPE test SYSTEM "dom1.dtd">
  13.  
  14. <test xmlns="http://www.w3.org/2001/DOM-Test-Suite/Level-1" name="documentcreateelementcasesensitive">
  15. <metadata>
  16. <title>documentCreateElementCaseSensitive</title>
  17. <creator>NIST</creator>
  18. <description>
  19.    The tagName parameter in the "createElement(tagName)"
  20.   method is case-sensitive for XML documents.
  21.   Retrieve the entire DOM document and invoke its
  22.   "createElement(tagName)" method twice.  Once for tagName
  23.   equal to "address" and once for tagName equal to "ADDRESS"
  24.   Each call should create a distinct Element node.  The
  25.   newly created Elements are then assigned attributes
  26.   that are retrieved.
  27. </description>
  28. <contributor>Mary Brady</contributor>
  29. <date qualifier="created">2001-08-17</date>
  30. <subject resource="http://www.w3.org/TR/1998/REC-DOM-Level-1-19981001/level-one-core#ID-2141741547"/>
  31. </metadata>
  32. <var name="doc" type="Document"/>
  33. <var name="newElement1" type="Element"/>
  34. <var name="newElement2" type="Element"/>
  35. <var name="attribute1" type="DOMString"/>
  36. <var name="attribute2" type="DOMString"/>
  37. <load var="doc" href="staff" willBeModified="true"/>
  38. <createElement obj="doc" var="newElement1" tagName="&quot;ADDRESS&quot;"/>
  39. <createElement obj="doc" var="newElement2" tagName="&quot;address&quot;"/>
  40. <setAttribute obj="newElement1" name="&quot;district&quot;" value="&quot;Fort Worth&quot;"/>
  41. <setAttribute obj="newElement2" name="&quot;county&quot;" value="&quot;Dallas&quot;"/>
  42. <getAttribute obj="newElement1" var="attribute1" name="&quot;district&quot;"/>
  43. <getAttribute obj="newElement2" var="attribute2" name="&quot;county&quot;"/>
  44. <assertEquals actual="attribute1" expected='"Fort Worth"' ignoreCase="false" id="attrib1"/>
  45. <assertEquals actual="attribute2" expected='"Dallas"' ignoreCase="false" id="attrib2"/>
  46. </test>
  47.