コード例 #1
0
 def test_str(self):
     contact = Contact(speaker=self.speaker,
                       kind='E',
                       value='*****@*****.**')
     self.assertEqual('*****@*****.**', str(contact))
コード例 #2
0
 def test_choice(self):
     """Contact kind should be limited to E or P"""
     contact = Contact(speaker=self.speaker, kind='A', value='B')
     self.assertRaises(ValidationError, contact.full_clean)
コード例 #3
0
 def test_str(self):
     contact = Contact(speaker=self.speaker, kind=Contact.EMAIL, value='*****@*****.**')
     self.assertEqual('*****@*****.**', str(contact))
コード例 #4
0
 def test_unicode(self):
     'Testa o unicode '
     contact = Contact(speaker=self.speaker, kind='E', value='*****@*****.**')
     self.assertEqual('*****@*****.**', unicode(contact))
コード例 #5
0
 def test_unicode(self):
     'Contact String representation should be value.'
     contact = Contact(speaker=self.speaker,
                       kind='E',
                       value='*****@*****.**')
     self.assertEqual('*****@*****.**', unicode(contact))
コード例 #6
0
ファイル: test_model_contact.py プロジェクト: puera/eventex
 def test_choices(self):
     """Tipo de contato deve ser limitado a E ou P"""
     contact = Contact(speaker=self.speaker, kind='A', value='B')
     self.assertRaises(ValidationError, contact.full_clean)
コード例 #7
0
 def test_str(self):
     contact = Contact(speaker=self.speaker, kind=Contact.EMAIL,
                                      value='*****@*****.**')
     self.assertEqual('*****@*****.**', str(contact))
コード例 #8
0
 def test_kind(self):
     """ Contact kind should be limited to P, F or E """
     contact = Contact(speaker=self.speaker,
                       kind='A',
                       value='21-98170-0339')
     self.assertRaises(ValidationError, contact.full_clean)
コード例 #9
0
 def test_unicode(self):
     """ Contact string representation should be unicode. """
     contact = Contact(speaker=self.speaker,
                       kind='E',
                       value='*****@*****.**')
     self.assertEquals(u'*****@*****.**', unicode(contact))
コード例 #10
0
ファイル: test_model_contact.py プロジェクト: olivx/eventex
 def test_str(self):
     contact = Contact(speaker=self.speaker, kind=Contact.EMAIL, value='*****@*****.**')
     self.assertEquals('*****@*****.**', str(contact))
コード例 #11
0
 def test_str(self):
     contact = Contact(speaker=self.speaker,
                       kind=Contact.EMAIL,
                       value='*****@*****.**')
     self.assertEqual('*****@*****.**', str(contact))
コード例 #12
0
ファイル: test_model_contact.py プロジェクト: rqclima/eventex
 def test_str(self):
     contact = Contact(speaker=self.speaker, kind=Contact.EMAIL, value='*****@*****.**')
     self.assertEqual('*****@*****.**', str(contact))
コード例 #13
0
 def test_str(self):
     contact = Contact(speaker=self.speaker,
                       kind=Contact.EMAIL,
                       value='*****@*****.**')
     self.assertEqual('*****@*****.**', str(contact))
コード例 #14
0
 def test_str(self):
     contact = Contact(speaker=self.speaker,
                       kind=Contact.EMAIL,
                       value='*****@*****.**')
     self.assertEqual('*****@*****.**', str(contact))
コード例 #15
0
ファイル: test_model_contact.py プロジェクト: eliezerfb/wttd
 def test_choiches(self):
     contact = Contact(speaker=self.speaker, kind='A', value='B')
     self.assertRaises(ValidationError, contact.full_clean)
コード例 #16
0
 def test_unicode(self):
     'Contact string representation sould be value.'
     contact = Contact(speaker=self.speaker,
                       kind='E',
                       value='*****@*****.**')
     self.assertEqual(u'*****@*****.**', unicode(contact))
コード例 #17
0
 def test_unicode(self):
     'Contact string representation should be value'
     contact = Contact(speaker=self.speaker,
                       kind='E',
                       value='*****@*****.**')
     self.assertEqual(u'*****@*****.**', unicode(contact))
コード例 #18
0
ファイル: test_models.py プロジェクト: arturfsousa/wttd8
 def test_kind(self):
     'Kind must be E, P or F.'
     contact = Contact(speaker=self.speaker, kind='J', value='B')
     self.assertRaises(ValidationError, contact.full_clean)
コード例 #19
0
 def test_choices(self):
     """ Contact should be limited to phone or email """
     contact = Contact(speaker=self.speaker, kind='A', value='test')
     self.assertRaises(ValidationError, contact.full_clean)
コード例 #20
0
 def test_unicode(self):
     'Contact string representation should be value'
     contact = Contact(speaker=self.speaker,
                       kind='E',
                       value='*****@*****.**')
     self.assertEqual(u'*****@*****.**', unicode(contact))
コード例 #21
0
 def test_kind(self):
     'Tipo contato deve estar limitado a E, P ou F'
     contact = Contact(speaker=self.speaker, kind='A', value='B')
     self.assertRaises(ValidationError, contact.full_clean)
コード例 #22
0
 def test_unicode(self):
     'Contact string representation should be value.'
     contact = Contact(speaker=self.speaker,
                       kind='E',
                       value='*****@*****.**')
     self.assertEqual(u'*****@*****.**', unicode(contact))
コード例 #23
0
 def test_kind(self):
     'Contact king should be limited to E, P or F.'
     contact = Contact(speaker=self.speaker, kind='A', value='B')
     self.assertRaises(ValidationError, contact.full_clean)
コード例 #24
0
 def test_str(self):
     contact = Contact(speaker=self.speaker,
                       kind=Contact.PHONE,
                       value="21-999999999")
     self.assertEqual("21-999999999", str(contact))
コード例 #25
0
 def test_str(self):
     contact = Contact(speaker=self.speaker, kind=Contact.EMAIL, value='*****@*****.**')
     self.assertEqual('*****@*****.**', str(contact))
コード例 #26
0
 def test_str(self):
     contact = Contact(speaker=self.speaker,
                       kind=Contact.EMAIL,
                       value='*****@*****.**')
     self.assertEqual('*****@*****.**', str(contact))
コード例 #27
0
    def test_str(self):
        contact = Contact(speaker=self.speaker,
                          kind=Contact.EMAIL,
                          value='*****@*****.**')

        self.assertEqual('*****@*****.**', str(contact))
コード例 #28
0
 def test_str(self):
     contact = Contact(speaker=self.speaker,
                       kind=Contact.EMAIL,
                       value='*****@*****.**')
     self.assertEqual('*****@*****.**', str(contact))