public void SetUp() { _validator = new PasswordValidator() { MinLenght = 8, Statements = new List<ValidatorStatement>() }; _validator.Statements.Add(new ValidatorStatement { ExpectedAtLeast = 2, Data = new HashSet<char>("0123456789") }); _validator.Statements.Add(new ValidatorStatement { ExpectedAtLeast = 2, Data = new HashSet<char>("ABCDEFGHIJKLMNOPQRSTUVWXYZ") }); _validator.Statements.Add(new ValidatorStatement { ExpectedAtLeast = 2, Data = new HashSet<char>("abcdefghijklmnopqrstuvwxyz") }); }
public AccountController(): base() { _db = new UsersDB(); _db.Database.CreateIfNotExists(); _validator = new PasswordValidator() { MinLenght = 8, Statements = new List<ValidatorStatement>() }; _validator.Statements.Add(new ValidatorStatement { ExpectedAtLeast = 2, Data = new HashSet<char>("0123456789") }); _validator.Statements.Add(new ValidatorStatement { ExpectedAtLeast = 2, Data = new HashSet<char>("ABCDEFGHIJKLMNOPQRSTUVWXYZ") }); _validator.Statements.Add(new ValidatorStatement { ExpectedAtLeast = 2, Data = new HashSet<char>("abcdefghijklmnopqrstuvwxyz") }); }
public Color GetPasswordColor(double value) { return(PasswordValidator.GetPasswordColor(value)); }