def testWriteXML(self): str = '<?xml version="1.0" ?><a b="c"/>' dom = parseString(str) domstr = dom.toxml() dom.unlink() self.confirm(str == domstr)