def parse(self, text): return parseString("%s%s%s" % (self._prefix, text, self._suffix))
def test_empty(self): m = parseString("<metadata/>") self.assertEqual(m, {})
def roundtrip(self, mapping): text = dumpString(mapping) parsed = parseString(text) self.assertEqual(parsed, mapping)