(self)
| 1051 | doc.unlink() |
| 1052 | |
| 1053 | def testNormalizeDeleteWithPrevSibling(self): |
| 1054 | doc = parseString("<doc/>") |
| 1055 | root = doc.documentElement |
| 1056 | root.appendChild(doc.createTextNode("first")) |
| 1057 | root.appendChild(doc.createTextNode("")) |
| 1058 | self.confirm(len(root.childNodes) == 2 |
| 1059 | and root.childNodes.length == 2, |
| 1060 | "testNormalizeDeleteWithPrevSibling -- preparation") |
| 1061 | doc.normalize() |
| 1062 | self.confirm(len(root.childNodes) == 1 |
| 1063 | and root.childNodes.length == 1 |
| 1064 | and root.firstChild.data == "first" |
| 1065 | and root.firstChild is root.lastChild |
| 1066 | and root.firstChild.nextSibling is None |
| 1067 | and root.firstChild.previousSibling is None |
| 1068 | , "testNormalizeDeleteWithPrevSibling -- result") |
| 1069 | doc.unlink() |
| 1070 | |
| 1071 | def testNormalizeDeleteWithNextSibling(self): |
| 1072 | doc = parseString("<doc/>") |
nothing calls this directly
no test coverage detected