示例#1
0
 public void ValidarCpfTest()
 {
     Assert.IsTrue(ValidacoesDominio.IsValid(ValidacoesDominio.ValidarCpf("764.181.250-37", "Validar CPF", this.GetType())));
     Assert.IsTrue(ValidacoesDominio.IsValid(ValidacoesDominio.ValidarCpf("76418125037", "Validar CPF", this.GetType())));
     Assert.IsFalse(ValidacoesDominio.IsValid(ValidacoesDominio.ValidarCpf("764.181.250-38", "Validar CPF", this.GetType())));
     Assert.IsFalse(ValidacoesDominio.IsValid(ValidacoesDominio.ValidarCpf("76418125038", "Validar CPF", this.GetType())));
     Assert.IsFalse(ValidacoesDominio.IsValid(ValidacoesDominio.ValidarCpf("000.000.000-00", "Validar CPF", this.GetType())));
     Assert.IsFalse(ValidacoesDominio.IsValid(ValidacoesDominio.ValidarCpf("111.111.111-11", "Validar CPF", this.GetType())));
     Assert.IsFalse(ValidacoesDominio.IsValid(ValidacoesDominio.ValidarCpf("222.222.222-22", "Validar CPF", this.GetType())));
     Assert.IsFalse(ValidacoesDominio.IsValid(ValidacoesDominio.ValidarCpf("333.333.333-33", "Validar CPF", this.GetType())));
     Assert.IsFalse(ValidacoesDominio.IsValid(ValidacoesDominio.ValidarCpf("444.444.444-44", "Validar CPF", this.GetType())));
     Assert.IsFalse(ValidacoesDominio.IsValid(ValidacoesDominio.ValidarCpf("555.555.555-55", "Validar CPF", this.GetType())));
     Assert.IsFalse(ValidacoesDominio.IsValid(ValidacoesDominio.ValidarCpf("666.666.666-66", "Validar CPF", this.GetType())));
     Assert.IsFalse(ValidacoesDominio.IsValid(ValidacoesDominio.ValidarCpf("777.777.777-77", "Validar CPF", this.GetType())));
     Assert.IsFalse(ValidacoesDominio.IsValid(ValidacoesDominio.ValidarCpf("888.888.888-88", "Validar CPF", this.GetType())));
     Assert.IsFalse(ValidacoesDominio.IsValid(ValidacoesDominio.ValidarCpf("999.999.999-99", "Validar CPF", this.GetType())));
 }