diff --git a/src/BrockAllen.MembershipReboot.Test/AccountService/UserAccountServiceTests.cs b/src/BrockAllen.MembershipReboot.Test/AccountService/UserAccountServiceTests.cs index cc268865..dbedf8a4 100644 --- a/src/BrockAllen.MembershipReboot.Test/AccountService/UserAccountServiceTests.cs +++ b/src/BrockAllen.MembershipReboot.Test/AccountService/UserAccountServiceTests.cs @@ -915,6 +915,7 @@ public void CloseAccount_ClosesAccount() Assert.IsTrue(acct.IsAccountClosed); Assert.IsNotNull(acct.AccountClosed); Assert.AreEqual(now, acct.AccountClosed.Value); + Assert.IsTrue(repository.UpdateWasCalled); } [TestMethod] @@ -2484,5 +2485,7 @@ public void Logging_in_before_account_is_verified_does_not_cause_account_to_have } + + } } diff --git a/src/BrockAllen.MembershipReboot.Test/FakeUserAccountRepository.cs b/src/BrockAllen.MembershipReboot.Test/FakeUserAccountRepository.cs index 42522deb..4805e395 100644 --- a/src/BrockAllen.MembershipReboot.Test/FakeUserAccountRepository.cs +++ b/src/BrockAllen.MembershipReboot.Test/FakeUserAccountRepository.cs @@ -14,6 +14,8 @@ protected internal override void AddClaim(UserClaim item) public class FakeUserAccountRepository : QueryableUserAccountRepository, IUserAccountRepository { + public bool UpdateWasCalled { get; set; } + public FakeUserAccountRepository() { this.UseEqualsOrdinalIgnoreCaseForQueries = true; @@ -43,6 +45,7 @@ public override void Remove(UserAccount item) public override void Update(UserAccount item) { + UpdateWasCalled = true; } public override UserAccount GetByLinkedAccount(string tenant, string provider, string id)