Пример #1
0
        private void AssertPasswordHistoryDidNotChangeInDb(string userName)
        {
            var savedPasswordHistoryDto = _simpleInMemoryDb.GetPasswordHistoryDto(userName);


            savedPasswordHistoryDto.UserName.Should().Be(userName);
            savedPasswordHistoryDto.CurrentPassword.Item1.Should().Be("password3");
            savedPasswordHistoryDto.PreviousPasswords.Select(t => t.Item1).Should().BeEquivalentTo(new List <string> {
                "password1", "password2"
            });
        }
Пример #2
0
        public PasswordHistory GetPasswordHistory(string userName, bool isHighProfileUser)
        {
            var passwordHistoryDto = _simpleInMemoryDb.GetPasswordHistoryDto(userName);

            return(ConvertToPasswordHistoryDomainObj(passwordHistoryDto, isHighProfileUser));
        }