示例#1
0
 def test_validate_masked_unicode_cpf_false(self):
     self.assertFalse(cpf.validate(u'111.444.777-38'))
示例#2
0
 def test_validate_cpf_unicode_false(self):
     self.assertFalse(cpf.validate(u'11144477736'))
示例#3
0
 def test_validate_masked_unicode_cpf_true(self):
     self.assertTrue(cpf.validate(u'111.444.777-35'))
示例#4
0
 def test_validate_cpf_with_same_numbers(self):
     for i in range(10):
         self.assertFalse(cpf.validate('{0}'.format(i) * 11))
示例#5
0
 def test_validate_cpf_unicode_true(self):
     self.assertTrue(cpf.validate(u'11144477735'))
示例#6
0
 def test_validate_masked_cpf_false(self):
     self.assertFalse(cpf.validate(self.masked_invalid_cpf))
示例#7
0
 def test_validate_cpf_false(self):
     self.assertFalse(cpf.validate(self.invalid_cpf))
示例#8
0
 def test_validate_masked_cpf_true(self):
     self.assertTrue(cpf.validate(self.masked_valid_cpf))
示例#9
0
 def test_cpf_no_masked_valid_true(self):
     """Test that CPF without masked is valid"""
     cpf_result = (self.cpf_mask_valid.replace(
         ".", "")).replace("-", "")
     self.assertTrue(cpf.validate(cpf_result))
示例#10
0
 def test_cpf_masked_valid_true(self):
     """Test that CPF masked valid is true"""
     self.assertTrue(cpf.validate(self.cpf_mask_valid))