示例#1
0
        public async Task ShouldCallCommitmentRepository()
        {
            _mockApprenticeshipRespository.Setup(x => x.BulkUploadApprenticeships(It.IsAny <long>(), It.IsAny <IEnumerable <Apprenticeship> >())).ReturnsAsync(new List <Apprenticeship>());

            await _handler.Handle(_exampleValidRequest);

            _mockApprenticeshipRespository.Verify(x => x.BulkUploadApprenticeships(It.IsAny <long>(), It.IsAny <IEnumerable <Apprenticeship> >()), Times.Once);
        }
示例#2
0
        public async Task ShouldDecodeLegalEntityPublicHashedIdBeforePassingItOn()
        {
            await _handler.Handle(_exampleValidRequest);

            _mockEncodingService.Verify(
                x => x.Decode(_existingCommitment.AccountLegalEntityPublicHashedId, EncodingType.PublicAccountLegalEntityId), Times.Once);
        }