コード例 #1
0
ファイル: test_common.py プロジェクト: totaler/switching
 def test_build_tree_with_prefix(self):
     c = Contacto()
     c.set_data(
         es_persona_juridica=False,
         nom="Perico",
         cognom_1="Palote",
         cognom_2=u"Pérez",
         telefon='555123123',
         prefix='01',
     )
     c.build_tree()
     xml = str(c)
     self.assertXmlEqual(xml, self.loadFile('Contacto_withprefix.xml'))
コード例 #2
0
ファイル: test_common.py プロジェクト: totaler/switching
 def test_build_tree_juridica(self):
     c = Contacto()
     c.set_data(
         es_persona_juridica=True,
         nom="Acme",
         cognom_1="",
         cognom_2="",
         telefon='',
         prefix='',
     )
     c.build_tree()
     xml = str(c)
     self.assertXmlEqual(xml, self.loadFile('Contacto_juridica.xml'))
コード例 #3
0
ファイル: test_common.py プロジェクト: gisce/switching
 def test_build_tree_with_phone(self):
     c = Contacto()
     c.set_data(
         es_persona_juridica=False,
         nom="Perico",
         cognom_1="Palote",
         cognom_2=u"Pérez",
         telefon="555123123",
         prefix="",
     )
     c.build_tree()
     xml = str(c)
     self.assertXmlEqual(xml, self.loadFile("Contacto_withphone.xml"))
コード例 #4
0
ファイル: test_common.py プロジェクト: Som-Energia/switching
 def test_build_tree_with_prefix(self):
     c = Contacto()
     c.set_data(
         es_persona_juridica=False,
         nom="Perico",
         cognom_1="Palote",
         cognom_2=u"Pérez",
         telefon='555123123',
         prefix='01',
     )
     c.build_tree()
     xml = str(c)
     self.assertXmlEqual(xml, self.loadFile('Contacto_withprefix.xml'))
コード例 #5
0
ファイル: test_common.py プロジェクト: Som-Energia/switching
 def test_build_tree_juridica(self):
     c = Contacto()
     c.set_data(
         es_persona_juridica=True,
         nom="Acme",
         cognom_1="",
         cognom_2="",
         telefon='',
         prefix='',
     )
     c.build_tree()
     xml = str(c)
     self.assertXmlEqual(xml, self.loadFile('Contacto_juridica.xml'))