MCPcopy Index your code
hub / github.com/python/cpython / test_read_from_stringio

Method test_read_from_stringio

Lib/test/test_xml_etree.py:4374–4378  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

4372 '''<site>\xf8</site>'''.encode("utf-16"))
4373
4374 def test_read_from_stringio(self):
4375 tree = ET.ElementTree()
4376 stream = io.StringIO('''<?xml version="1.0"?><site></site>''')
4377 tree.parse(stream)
4378 self.assertEqual(tree.getroot().tag, 'site')
4379
4380 def test_write_to_stringio(self):
4381 tree = ET.ElementTree(ET.XML('''<site>\xf8</site>'''))

Callers

nothing calls this directly

Calls 3

parseMethod · 0.95
getrootMethod · 0.95
assertEqualMethod · 0.45

Tested by

no test coverage detected