public void ChangePassword_GetChangedPassword() { //Arrange var accountFacade = new AccountFacade(_keysRepository, _userRepository, _emailSender.Object, userSettings); var userFacade = new UserFacade(_userRepository, _groupRepository, _eventRepository, _publisher.Object); var expectedPasswordHash = Credentials.FromRawData("someEmail", "newPassword").PasswordHash; var userId = accountFacade.RegUser("Alena", Credentials.FromRawData("email", "password"), true); //Act accountFacade.ChangePassword(userId, "newPassword"); var currentUser = userFacade.GetUser(userId); //Assert Assert.AreEqual(expectedPasswordHash, currentUser.Credentials.PasswordHash); }