| OLD | NEW |
| 1 | 1 |
| 2 /* | 2 /* |
| 3 Copyright © 2001-2004 World Wide Web Consortium, | 3 Copyright © 2001-2004 World Wide Web Consortium, |
| 4 (Massachusetts Institute of Technology, European Research Consortium | 4 (Massachusetts Institute of Technology, European Research Consortium |
| 5 for Informatics and Mathematics, Keio University). All | 5 for Informatics and Mathematics, Keio University). All |
| 6 Rights Reserved. This work is distributed under the W3C® Software License [1] i
n the | 6 Rights Reserved. This work is distributed under the W3C® Software License [1] i
n the |
| 7 hope that it will be useful, but WITHOUT ANY WARRANTY; without even | 7 hope that it will be useful, but WITHOUT ANY WARRANTY; without even |
| 8 the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. | 8 the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. |
| 9 | 9 |
| 10 [1] http://www.w3.org/Consortium/Legal/2002/copyright-software-20021231 | 10 [1] http://www.w3.org/Consortium/Legal/2002/copyright-software-20021231 |
| (...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 92 var attrPosition; | 92 var attrPosition; |
| 93 var replacedAttr; | 93 var replacedAttr; |
| 94 | 94 |
| 95 var docRef = null; | 95 var docRef = null; |
| 96 if (typeof(this.doc) != 'undefined') { | 96 if (typeof(this.doc) != 'undefined') { |
| 97 docRef = this.doc; | 97 docRef = this.doc; |
| 98 } | 98 } |
| 99 doc = load(docRef, "doc", "hc_staff"); | 99 doc = load(docRef, "doc", "hc_staff"); |
| 100 elemList = doc.getElementsByTagName("p"); | 100 elemList = doc.getElementsByTagName("p"); |
| 101 elem = elemList.item(3); | 101 elem = elemList.item(3); |
| 102 newAttr = doc.createAttributeNS("http://www.w3.org/XML/1998/namespace","xm
l:lang"); | 102 newAttr = doc.createAttribute("xml:lang"); |
| 103 replacedAttr = elem.setAttributeNode(newAttr); | 103 replacedAttr = elem.setAttributeNode(newAttr); |
| 104 attrPosition = newAttr.compareDocumentPosition(doc); | 104 attrPosition = newAttr.compareDocumentPosition(doc); |
| 105 assertEquals("nodecomparedocumentpositionPRECEDINGContains11",10,attrPosit
ion); | 105 assertEquals("nodecomparedocumentpositionPRECEDINGContains11",10,attrPosit
ion); |
| 106 | 106 |
| 107 } | 107 } |
| 108 | 108 |
| 109 | 109 |
| 110 | 110 |
| 111 | 111 |
| 112 function runTest() { | 112 function runTest() { |
| 113 nodecomparedocumentposition11(); | 113 nodecomparedocumentposition11(); |
| 114 } | 114 } |
| OLD | NEW |