Exemple #1
0
        public void IsStrongPasswordTest(string password, bool expected)
        {
            var passwordStrengthValidator = new PasswordStrengthValidator();
            var actual = passwordStrengthValidator.IsStrongPassword(password);

            Assert.Equal(expected, actual);
        }
Exemple #2
0
 public UsersLogic()
 {
     EmailValidator    = new EmailValidator();
     BirthDayValidator = new DateValidator()
     {
         MinimumDate = new DateTime(1900, 1, 1),
         MaximumDate = DateTime.Now - TimeSpan.FromDays(365 * 10)
     };
     PasswordStrengthValidator = new PasswordStrengthValidator()
     {
         MinimumLength = 6
     };
 }