public UserManagerTest()
        {
            var hashedPassword = new StandardPasswordHasher().HashPassword(Password);

            IUser user = new WcfBankingService.Users.User(Login, hashedPassword);

            _accessToken = user.GenerateAccessToken(Password);
            Assert.IsNotNull(_accessToken);

            _accountNumber = new AccountNumber("12345678", "1234567891234321", "12");
            IAccount account = new WcfBankingService.Accounts.Account(_accountNumber, new Balance(122m));

            Assert.IsTrue(user.AddAccount(_accessToken, account));

            var userList = new List <IUser>
            {
                user
            };

            _userManager = new UserManager(new MockDataProvider(userList));
        }
Example #2
0
 public StandardPasswordHasherTest()
 {
     _hasher = new StandardPasswordHasher();
 }