(self)
| 1069 | doc.unlink() |
| 1070 | |
| 1071 | def testNormalizeDeleteWithNextSibling(self): |
| 1072 | doc = parseString("<doc/>") |
| 1073 | root = doc.documentElement |
| 1074 | root.appendChild(doc.createTextNode("")) |
| 1075 | root.appendChild(doc.createTextNode("second")) |
| 1076 | self.confirm(len(root.childNodes) == 2 |
| 1077 | and root.childNodes.length == 2, |
| 1078 | "testNormalizeDeleteWithNextSibling -- preparation") |
| 1079 | doc.normalize() |
| 1080 | self.confirm(len(root.childNodes) == 1 |
| 1081 | and root.childNodes.length == 1 |
| 1082 | and root.firstChild.data == "second" |
| 1083 | and root.firstChild is root.lastChild |
| 1084 | and root.firstChild.nextSibling is None |
| 1085 | and root.firstChild.previousSibling is None |
| 1086 | , "testNormalizeDeleteWithNextSibling -- result") |
| 1087 | doc.unlink() |
| 1088 | |
| 1089 | def testNormalizeDeleteWithTwoNonTextSiblings(self): |
| 1090 | doc = parseString("<doc/>") |
nothing calls this directly
no test coverage detected