public void Init()
        {
            _appServiceSettings = new Mock <IAppServiceSettings>();
            _mockLogger         = new Mock <ILog>();

            var metaDataFactories = new List <IMetaDataFactory>
            {
                new FrameworkMetaDataFactory(),
                new FrameworkAimMetaDataFactory(),
                new FrameworkComponentTypeMetaDataFactory(),
                new LearningDeliveryMetaDataFactory()
            };

            _readMetaDataFromCsv = new CsvService(new LarsMetaDataFactory(metaDataFactories));
            _fileExtractor       = new ZipFileExtractor();
            _angleSharpService   = new AngleSharpService(new HttpService(_mockLogger.Object));
            _httpGetFile         = new HttpService(_mockLogger.Object);

            _sut = new LarsDataService(
                _appServiceSettings.Object,
                _readMetaDataFromCsv,
                _httpGetFile,
                _fileExtractor,
                _angleSharpService,
                _mockLogger.Object);
        }
Ejemplo n.º 2
0
 public LarsDataService(
     IHttpClient httpClient,
     IAngleSharpService angleSharpService,
     IUnzipStream zipFileExtractor,
     IAppSettings appSettings)
 {
     _httpClient        = httpClient;
     _angleSharpService = angleSharpService;
     _zipFileExtractor  = zipFileExtractor;
     _appSettings       = appSettings;
 }
Ejemplo n.º 3
0
 public LarsDataService(
     IAppServiceSettings appServiceSettings,
     IReadMetaDataFromCsv csvService,
     IHttpGetFile httpGetFile,
     IUnzipStream fileExtractor,
     IAngleSharpService angleSharpService,
     ILog logger)
 {
     _appServiceSettings = appServiceSettings;
     _csvService         = csvService;
     _httpGetFile        = httpGetFile;
     _fileExtractor      = fileExtractor;
     _angleSharpService  = angleSharpService;
     _logger             = logger;
 }