Exemplo n.º 1
0
 def test_xml_with_semicolon(self):
     xmldata = libxml2.parseFile("data/vcard_with_semicolon.xml")
     vc = vcard.VCard(xmldata.getRootElement())
     first = vc.rfc2426()
     second = vcard.VCard(first).rfc2426()
     self.failUnlessEqual(first, second)
Exemplo n.º 2
0
 def test_vcf_input2(self):
     input = file("data/vcard3.vcf").read()
     vc = vcard.VCard(input)
     should_be = file("data/vcard3.txt").read()
     self.failUnlessEqual(vcard2txt(vc), should_be)
Exemplo n.º 3
0
 def test_xml_without_fn(self):
     xmldata = libxml2.parseFile("data/vcard_without_n.xml")
     vc = vcard.VCard(xmldata.getRootElement())
     should_be = file("data/vcard_without_n.txt").read()
     self.failUnlessEqual(vcard2txt(vc), should_be)