Add additional verification in rehash password test

This commit is contained in:
Hao Kung 2016-08-17 12:44:22 -07:00
parent fa976e7765
commit 526d9f0076
1 changed files with 1 additions and 0 deletions

View File

@ -466,6 +466,7 @@ namespace Microsoft.AspNetCore.Identity.Test
store.Setup(s => s.GetPasswordHashAsync(user, CancellationToken.None))
.ReturnsAsync(hashed)
.Verifiable();
store.Setup(s => s.SetPasswordHashAsync(user, It.IsAny<string>(), CancellationToken.None)).Returns(Task.FromResult(0)).Verifiable();
store.Setup(x => x.UpdateAsync(It.IsAny<TestUser>(), It.IsAny<CancellationToken>())).Returns(Task.FromResult(IdentityResult.Success));
hasher.Setup(s => s.VerifyHashedPassword(user, hashed, pwd)).Returns(PasswordVerificationResult.SuccessRehashNeeded).Verifiable();