MCPcopy Index your code
hub / github.com/RustPython/RustPython / test_1463026_3

Method test_1463026_3

Lib/test/test_sax.py:691–703  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

689 self.assertEqual(result.getvalue(), self.xml('<a xmlns="qux"/>'))
690
691 def test_1463026_3(self):
692 result = self.ioclass()
693 gen = XMLGenerator(result)
694
695 gen.startDocument()
696 gen.startPrefixMapping('my', 'qux')
697 gen.startElementNS(('qux', 'a'), 'a', {(None, 'b'):'c'})
698 gen.endElementNS(('qux', 'a'), 'a')
699 gen.endPrefixMapping('my')
700 gen.endDocument()
701
702 self.assertEqual(result.getvalue(),
703 self.xml('<my:a xmlns:my="qux" b="c"></my:a>'))
704
705 def test_1463026_3_empty(self):
706 result = self.ioclass()

Callers

nothing calls this directly

Calls 11

startDocumentMethod · 0.95
startPrefixMappingMethod · 0.95
startElementNSMethod · 0.95
endElementNSMethod · 0.95
endPrefixMappingMethod · 0.95
endDocumentMethod · 0.95
XMLGeneratorClass · 0.90
ioclassMethod · 0.45
assertEqualMethod · 0.45
getvalueMethod · 0.45
xmlMethod · 0.45

Tested by

no test coverage detected