summaryrefslogtreecommitdiffstats
path: root/Lib/test/test_xml_etree.py
diff options
context:
space:
mode:
Diffstat (limited to 'Lib/test/test_xml_etree.py')
-rw-r--r--Lib/test/test_xml_etree.py4
1 files changed, 4 insertions, 0 deletions
diff --git a/Lib/test/test_xml_etree.py b/Lib/test/test_xml_etree.py
index 9746934..68dd1cc 100644
--- a/Lib/test/test_xml_etree.py
+++ b/Lib/test/test_xml_etree.py
@@ -1904,6 +1904,10 @@ class ElementIterTest(unittest.TestCase):
tree = ET.ElementTree(None)
self.assertRaises(AttributeError, tree.iter)
+ # Issue #16913
+ doc = ET.XML("<root>a&amp;<sub>b&amp;</sub>c&amp;</root>")
+ self.assertEqual(''.join(doc.itertext()), 'a&b&c&')
+
def test_corners(self):
# single root, no subelements
a = ET.Element('a')