public void Then_The_HashedAccountId_Is_Stored() { _employerAccountController.GatewayInform(hashedAccountId: _hashedAccountId); _mockAccountCookieStorage .Verify( m => m.Delete(_cookieKeyName)); _mockAccountCookieStorage .Verify( m => m.Create( It.Is <HashedAccountIdModel>(model => model.Value.Equals(_hashedAccountId)), It.Is <string>(key => key.Equals(_cookieKeyName)), It.IsAny <int>()) ); }
public void Then_The_HashedAccountId_Is_Not_Stored(string hashedAccountId) { _employerAccountController.GatewayInform(hashedAccountId: hashedAccountId); _mockAccountCookieStorage .Verify( m => m.Delete(It.IsAny <string>()), Times.Never()); _mockAccountCookieStorage .Verify( m => m.Create( It.IsAny <HashedAccountIdModel>(), It.IsAny <string>(), It.IsAny <int>()), Times.Never ); }