public void PasswordContainsCharactersFromUpperCaseNumberAndSpecialClasses()
        {
            var sut = new PasswordCharacterSpecification(3);
            bool result = sut.IsSatisfiedBy(new Password("ABC123#%&"));

            Assert.IsTrue(result);
        }
        public void PasswordContainsCharactersFromAllClasses()
        {
            var sut = new PasswordCharacterSpecification(4);
            bool result = sut.IsSatisfiedBy(new Password("abcABC123&%#"));

            Assert.IsTrue(result);
        }
        public void PasswordContainsCharactersFromLowerCaseUpperCaseAndNumberClasses()
        {
            var sut = new PasswordCharacterSpecification(3);
            bool result = sut.IsSatisfiedBy(new Password("abcABC123"));

            Assert.IsTrue(result);
        }
        public void PasswordContainsOnlyUpperCaseAndLowerCaseClasses()
        {
            var sut = new PasswordCharacterSpecification(3);
            bool result = sut.IsSatisfiedBy(new Password("ABCabc"));

            Assert.IsFalse(result);
            Assert.AreEqual(1, sut.ReasonsForDissatisfaction.Count());
            Assert.AreEqual(PasswordCharacterSpecification.PasswordDoesNotContainEnoughCharacterClasses, sut.ReasonsForDissatisfaction.Single());
        }
 public void PasswordCannotBeNull()
 {
     var sut = new PasswordCharacterSpecification(1);
     sut.IsSatisfiedBy(null);
 }