summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_minidom.py
diff options
context:
space:
mode:
authorAndrew M. Kuchling <amk@amk.ca>2008-02-23 17:10:46 (GMT)
committerAndrew M. Kuchling <amk@amk.ca>2008-02-23 17:10:46 (GMT)
commit19aff0c90a1632fce527d7c81769ba419184700c (patch)
treeca3941db3a16a3ebd33991d66242d9f9ec5326c3 /Lib/test/test_minidom.py
parent8887e548674d34da0a9e025e68a1f55ff57a8752 (diff)
downloadcpython-19aff0c90a1632fce527d7c81769ba419184700c.zip
cpython-19aff0c90a1632fce527d7c81769ba419184700c.tar.gz
cpython-19aff0c90a1632fce527d7c81769ba419184700c.tar.bz2
#1433694: minidom's .normalize() failed to set .nextSibling for last element.
Fix by Malte Helmert
Diffstat (limited to 'Lib/test/test_minidom.py')
-rw-r--r--Lib/test/test_minidom.py8
1 files changed, 8 insertions, 0 deletions
diff --git a/Lib/test/test_minidom.py b/Lib/test/test_minidom.py
index 3058b30..fcc4c8f 100644
--- a/Lib/test/test_minidom.py
+++ b/Lib/test/test_minidom.py
@@ -791,6 +791,14 @@ class MinidomTest(unittest.TestCase):
"testNormalize -- single empty node removed")
doc.unlink()
+ def testBug1433694(self):
+ doc = parseString("<o><i/>t</o>")
+ node = doc.documentElement
+ node.childNodes[1].nodeValue = ""
+ node.normalize()
+ self.confirm(node.childNodes[-1].nextSibling == None,
+ "Final child's .nextSibling should be None")
+
def testSiblings(self):
doc = parseString("<doc><?pi?>text?<elm/></doc>")
root = doc.documentElement