public void TestEmailValidation() { const string email = "*****@*****.**"; var validationEmail = new ValidationEmail(); validationEmail.Validate(email); }
public string ValidateForm(string firstName, string lastName, string email, string age) { try { _validationText.Validate(firstName); _validationText.Validate(lastName); _validationEmail.Validate(email); _validationNumber.Validate(age); return("Validation successfully"); } catch (Exception ex) { return(ex.Message); } }