public void WhenMoreThanMinLength_ReturnsSuccess(string password)
        {
            var validator = new MinLengthNewPasswordValidator();

            validator.Configure(8);

            var context = new NewPasswordValidationContext()
            {
                Password = password
            };

            var result = validator.Validate(context);

            result.Should().BeNull();
        }
        public void WhenLessThanMinLength_ReturnsError()
        {
            var validator = new MinLengthNewPasswordValidator();

            validator.Configure(8);

            var context = new NewPasswordValidationContext()
            {
                Password = "******"
            };

            var result = validator.Validate(context);

            result.Should().NotBeNull();
            result.ErrorCode.Should().Be(PasswordPolicyValidationErrors.MinLengthNotMet.ErrorCode);
        }