public void ValidateRole(string adUser)
 {
     try
     {
         adUser = _config.DomainUser + adUser;
         var response = _role.ValidateRole(adUser);
         Console.WriteLine(response);
     }
     catch (Exception ex)
     {
         Assert.True(false, ex.Message);
     }
 }
        /// <summary>
        /// Validate username and password is valid.
        /// </summary>
        /// <param name="login">The login value.</param>
        /// <returns></returns>
        public ResultViewModel Authenticate(LoginViewModel login)
        {
            var result = new ResultViewModel();

            if (_adService.Authen(login.Username, login.Password))
            {
                login.Username = $"{_config.DomainUser}{login.Username}";
                result         = _roleBll.ValidateRole(login.Username);
            }
            else
            {
                result = UtilityService.InitialResultError(MessageValue.LoginFailed, 401);
            }
            return(result);
        }