public void ThenRequestRepositoryGetRequestsBySenderIdShouldHaveBeenCalled() => RequestsRepository.Verify(repo => repo.GetRequestsByReceiverId(_userId), Times.Once);
public void ThenRequestsRepositoryGetRequestByUserIdsAndTypeShouldHaveBeenCalled() => RequestsRepository.Verify(repository => repository.GetRequestByUserIdsAndType(It.IsAny <Request>()), Times.Once);
public void ThenRequestsRepositoryGetRequestByUserIdsAndTypeShouldNotHaveBeenCalled() => RequestsRepository.Verify( repository => repository.GetRequestByUserIdsAndType(It.IsAny <Guid>(), It.IsAny <Guid>(), It.IsAny <RequestType>()), Times.Never);
public void ThenRequestsRepositoryGetRequestByUserIdsAndTypeShouldHaveBeenCalled() => RequestsRepository.Verify( repository => repository.GetRequestByUserIdsAndType(_userId, _senderId, (RequestType)RequestTypeId), Times.Once);
public void ThenRequestRepositoryCreateRequestShouldNotHaveBeenCalled() => RequestsRepository.Verify(repo => repo.CreateRequest(It.IsAny <Request>()), Times.Never);
public void ThenRequestRepositoryCreateRequestShouldHaveBeenCalled() => RequestsRepository.Verify(repo => repo.CreateRequest(It.Is <Request>(request => request.SenderId == _requestRequest.SenderId && request.ReceiverId == _requestRequest.ReceiverId && request.RequestType == (RequestType)_requestRequest.RequestTypeId)));
public void ThenRequestsRepositoryDeleteRequestShouldHaveBeenCalled() => RequestsRepository.Verify( repository => repository.DeleteRequest(_request.SenderId, _request.ReceiverId, RequestType.Friend), Times.Once);