public RegistrationController(ResultsAndCertificationConfiguration configuration, ICsvHelperService <RegistrationCsvRecord, Registration, ImportResponseRecord <Registration> > csvParserService, IRegistrationService registrationService, IBlobStorageService blobStorageService)
 {
     _configuration       = configuration;
     _csvParserService    = csvParserService;
     _registrationService = registrationService;
     _blobStorageService  = blobStorageService;
 }
Esempio n. 2
0
 public SftpService(ConnectionSftp sftpConfig,
                    ICsvHelperService csvHelperService,
                    ILogService logService)
 {
     _config           = sftpConfig ?? throw new ArgumentNullException(nameof(sftpConfig));
     _csvHelperService = csvHelperService ?? throw new ArgumentNullException(nameof(csvHelperService));
     _logService       = logService ?? throw new ArgumentNullException(nameof(logService));
 }
 public BulkRegistrationLoader(ICsvHelperService <RegistrationCsvRecordRequest, CsvResponseModel <RegistrationCsvRecordResponse>, RegistrationCsvRecordResponse> csvService,
                               IRegistrationService registrationService,
                               IBlobStorageService blobStorageService,
                               IDocumentUploadHistoryService documentUploadHistoryService,
                               ILogger <BulkRegistrationLoader> logger) : base(blobStorageService, documentUploadHistoryService)
 {
     _csvService          = csvService;
     _registrationService = registrationService;
     _blobStorageService  = blobStorageService;
     _logger = logger;
 }
Esempio n. 4
0
 public BulkAssessmentLoader(ICsvHelperService <AssessmentCsvRecordRequest, CsvResponseModel <AssessmentCsvRecordResponse>, AssessmentCsvRecordResponse> csvService,
                             IAssessmentService assessmentService,
                             IBlobStorageService blobStorageService,
                             IDocumentUploadHistoryService documentUploadHistoryService,
                             ILogger <BulkAssessmentLoader> logger) : base(blobStorageService, documentUploadHistoryService)
 {
     _csvService         = csvService;
     _assessmentService  = assessmentService;
     _blobStorageService = blobStorageService;
     _logger             = logger;
 }
        public override void Setup()
        {
            CsvService    = Substitute.For <ICsvHelperService <ResultCsvRecordRequest, CsvResponseModel <ResultCsvRecordResponse>, ResultCsvRecordResponse> >();
            ResultService = Substitute.For <IResultService>();
            BlobService   = Substitute.For <IBlobStorageService>();
            Logger        = Substitute.For <ILogger <BulkResultLoader> >();
            DocumentUploadHistoryService = Substitute.For <IDocumentUploadHistoryService>();

            BlobUniqueRef = Guid.NewGuid();

            Request = new BulkProcessRequest
            {
                AoUkprn             = 1234567891,
                BlobFileName        = "Results.csv",
                BlobUniqueReference = BlobUniqueRef,
                DocumentType        = DocumentType.Results,
                FileType            = FileType.Csv,
                PerformedBy         = "TestUser",
            };
        }
 public ImportFileController(ICsvHelperService csvHelper)
 {
     _csvHelper = csvHelper;
 }