public AdminFileExtractRequest(AssessorClarificationOutcome assessorClarification) { ApplicationId = assessorClarification.ApplicationId; PageId = assessorClarification.PageId; SectionNumber = assessorClarification.SectionNumber; SequenceNumber = assessorClarification.SequenceNumber; Filename = assessorClarification.ClarificationFile; AdminFileType = AdminFileType.Assessor; }
public async Task Run_Downloads_and_Saves_Assessor_File_Into_BlobStorage() { var assessorClarificationOutcome = new AssessorClarificationOutcome { ApplicationId = _applicationId, ClarificationFile = "file.pdf" }; var request = new AdminFileExtractRequest(assessorClarificationOutcome); await _sut.Run(request); _applyApiClient.Verify(x => x.DownloadAssessorClarificationFile(assessorClarificationOutcome.ApplicationId, assessorClarificationOutcome.SequenceNumber, assessorClarificationOutcome.SectionNumber, assessorClarificationOutcome.PageId, assessorClarificationOutcome.ClarificationFile), Times.AtLeastOnce); _blobClient.Verify(x => x.UploadAsync(It.IsAny <Stream>(), true, It.IsAny <CancellationToken>()), Times.Once); }