private void SetUpBlobClientProvider()
 {
     _blobClientProvider = Substitute.For <IBlobClientProvider>();
     _blobClientProvider.GetBlobClient(_humidityFilePath).Returns(_humidityBlob);
     _blobClientProvider.GetBlobClient(_rainfallFilePath).Returns(_rainfallBlob);
     _blobClientProvider.GetBlobClient(_temperatureFilePath).Returns(_temperatureBlob);
     _blobClientProvider.GetBlobClient(_humidityHistoricalFilePath).Returns(_humidityHistoricalBlob);
     _blobClientProvider.GetBlobClient(_rainfallHistoricalFilePath).Returns(_rainfallHistoricalBlob);
     _blobClientProvider.GetBlobClient(_temperatureHistoricalFilePath).Returns(_temperatureHistoricalBlob);
 }
Esempio n. 2
0
        public ChannelMessageSender(ILogger <ChannelMessageSender> logger,
                                    IConfiguration configuration, IBlobClientProvider blobClientProvider)
        {
            _logger             = logger;
            _configuration      = configuration;
            _blobClientProvider = blobClientProvider;

            _serviceBusConfiguration = configuration.GetSection(ServiceBusConfigurationKey).Get <ServiceBusConfiguration>();

            _blobConfiguration = BlobConfigurationUtil.GetBlobConfigiration(configuration);
        }
Esempio n. 3
0
 public DevicesHandler(
     IParserProvider parserProvider,
     IFilePathBuilder filePathBuilder,
     IBlobClientProvider blobClientProvider,
     Func <Stream, ZipArchive> zipArchiveProvider,
     IDeviceDataBuilder deviceDataBuilder)
 {
     _parserProvider     = parserProvider;
     _filePathBuilder    = filePathBuilder;
     _blobClientProvider = blobClientProvider;
     _zipArchiveProvider = zipArchiveProvider;
     _deviceDataBuilder  = deviceDataBuilder;
 }
Esempio n. 4
0
 public FileDeleter(IBlobClientProvider blobClientProvider)
 {
     _blobClient = blobClientProvider.Get();
 }
Esempio n. 5
0
 public SharedAccessSignatureProvider(IBlobClientProvider blobClientProvider)
 {
     _blobClient = blobClientProvider.Get();
 }