コード例 #1
0
        public void CheckLogin_WhenUserNameAndUserPasswordIsValid_ShouldReturnTrue()
        {
            string userToTest     = "123";
            string passwordToTest = "password";

            _cryptoService.Setup(hash => hash.HashSHA512(passwordToTest, _userTest.PasswordSalt)).Returns(passwordToTest);
            _authentificationService.LogIn(userToTest, passwordToTest);
            Assert.True(_authentificationService.IsUserAuthenticated);
        }