public LoginData UserAuthentication(String user, String pass) { LoginData loginData = new LoginData(); LoginAuthentication login = new LoginAuthentication(); if (login.CredentialsAuthentication(user, pass).Equals(validationResult.Success)) { loginData.TipoUsuario = login.GetUserType(user, pass); loginData.Result = validationResult.Success; } else { loginData.Result = validationResult.UserOrPasswordIncorrect; } return(loginData); }
public void CredentialsAuthenticationTest() { LoginAuthentication login = new LoginAuthentication(); Assert.AreEqual(login.CredentialsAuthentication("eldavis", "del2al5"), LoginAuthentication.validationResult.Success); }
public void CredentialsAuthenticationTest() { LoginAuthentication login = new LoginAuthentication(); Assert.AreEqual(login.CredentialsAuthentication("s17012959", "A2B4c6d8"), LoginAuthentication.validationResult.Success); }