Test `QName` escaping.
(self)
| 635 | self.assertRaises(ValueError, markdown.serializers.to_xhtml_string, el) |
| 636 | |
| 637 | def testQNameEscaping(self): |
| 638 | """ Test `QName` escaping. """ |
| 639 | qname = etree.QName('<&"test\nescaping">', 'div') |
| 640 | el = etree.Element(qname) |
| 641 | self.assertEqual( |
| 642 | markdown.serializers.to_xhtml_string(el), |
| 643 | '<div xmlns="<&"test escaping">"></div>' |
| 644 | ) |
| 645 | |
| 646 | def testQNamePreEscaping(self): |
| 647 | """ Test `QName` that is already partially escaped. """ |
nothing calls this directly
no outgoing calls
no test coverage detected