summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_xml_etree.py
diff options
context:
space:
mode:
authorChristian Heimes <christian@cheimes.de>2013-07-04 23:39:49 (GMT)
committerChristian Heimes <christian@cheimes.de>2013-07-04 23:39:49 (GMT)
commit54ad7e39dfe429795cc908a9a03a94c485c87cc2 (patch)
tree453c78e1fa5cd4f12bd09314a418f9df238a1f34 /Lib/test/test_xml_etree.py
parentbe9c8414945dc15c079d07a0b84597142ea41511 (diff)
downloadcpython-54ad7e39dfe429795cc908a9a03a94c485c87cc2.zip
cpython-54ad7e39dfe429795cc908a9a03a94c485c87cc2.tar.gz
cpython-54ad7e39dfe429795cc908a9a03a94c485c87cc2.tar.bz2
Issue #18347: ElementTree's html serializer now preserves the case of closing tags.
Diffstat (limited to 'Lib/test/test_xml_etree.py')
-rw-r--r--Lib/test/test_xml_etree.py7
1 files changed, 7 insertions, 0 deletions
diff --git a/Lib/test/test_xml_etree.py b/Lib/test/test_xml_etree.py
index 4a586bd..4c2e26f 100644
--- a/Lib/test/test_xml_etree.py
+++ b/Lib/test/test_xml_etree.py
@@ -751,6 +751,13 @@ class ElementTreeTest(unittest.TestCase):
'<html><link><script>1 < 2</script></html>\n')
self.assertEqual(serialize(e, method="text"), '1 < 2\n')
+ def test_issue18347(self):
+ e = ET.XML('<html><CamelCase>text</CamelCase></html>')
+ self.assertEqual(serialize(e),
+ '<html><CamelCase>text</CamelCase></html>')
+ self.assertEqual(serialize(e, method="html"),
+ '<html><CamelCase>text</CamelCase></html>')
+
def test_entity(self):
# Test entity handling.