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) 2004 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 "dom2.dtd">
  13.  
  14. <test xmlns="http://www.w3.org/2001/DOM-Test-Suite/Level-2" name="hc_notationssetnameditemns1">
  15. <metadata>
  16. <title>hc_notationssetnameditemns1</title>
  17. <creator>Curt Arnold</creator>
  18. <description>
  19. An attempt to add an element to the named node map returned by notations should
  20. result in a NO_MODIFICATION_ERR or HIERARCHY_REQUEST_ERR.
  21. </description>
  22. <date qualifier="created">2004-01-11</date>
  23. <!--  DocumentType.notations   -->
  24. <subject resource="http://www.w3.org/TR/DOM-Level-2-Core/core#ID-D46829EF"/>
  25. <!--  NamedNodeMap.setNamedItemNS   -->
  26. <subject resource="http://www.w3.org/TR/DOM-Level-2-Core/core#ID-setNamedItemNS"/>
  27. </metadata>
  28. <var name="doc" type="Document"/>
  29. <var name="notations" type="NamedNodeMap"/>
  30. <var name="docType" type="DocumentType"/>
  31. <var name="retval" type="Node"/>
  32. <var name="elem" type="Element"/>
  33. <load var="doc" href="hc_staff" willBeModified="true"/>
  34. <doctype var="docType" obj="doc"/>
  35. <if><not><contentType type="text/html"/></not>
  36. <assertNotNull actual="docType" id="docTypeNotNull"/>
  37. <notations var="notations" obj="docType"/>
  38. <assertNotNull actual="notations" id="notationsNotNull"/>
  39. <createElementNS var="elem" obj="doc" namespaceURI='"http://www.w3.org/1999/xhtml"' qualifiedName='"br"'/>
  40. <try>
  41.         <setNamedItemNS var="retval" obj="notations" arg="elem"/>
  42.         <fail id="throw_HIER_OR_NO_MOD_ERR"/>
  43.         <catch>
  44.                 <DOMException code="HIERARCHY_REQUEST_ERR"/>
  45.                 <DOMException code="NO_MODIFICATION_ALLOWED_ERR"/>
  46.         </catch>
  47. </try>
  48. </if>
  49. </test>
  50.