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

Method test_cdata_parsing

Lib/test/test_minidom.py:1780–1785  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

1778 '</root>\n')
1779
1780 def test_cdata_parsing(self):
1781 xml_str = '<?xml version="1.0" ?><root><node><![CDATA[</data>]]></node></root>'
1782 dom1 = parseString(xml_str)
1783 self.checkWholeText(dom1.getElementsByTagName('node')[0].firstChild, '</data>')
1784 dom2 = parseString(dom1.toprettyxml())
1785 self.checkWholeText(dom2.getElementsByTagName('node')[0].firstChild, '</data>')
1786
1787if __name__ == "__main__":
1788 unittest.main()

Callers

nothing calls this directly

Calls 4

checkWholeTextMethod · 0.95
parseStringFunction · 0.90
toprettyxmlMethod · 0.80
getElementsByTagNameMethod · 0.45

Tested by

no test coverage detected