Exemplo n.º 1
0
        public void Setup()
        {
            fakeScsStorageService = A.Fake <ISalesCatalogueStorageService>();
            fakeStorageConfig     = Options.Create(new EssFulfilmentStorageConfiguration()
            {
                QueueName                    = "",
                StorageAccountKey            = "",
                StorageAccountName           = "",
                StorageContainerName         = "",
                DynamicQueueName             = "ess-{0}-test",
                LargeExchangeSetAccountKey   = "LargeExchangeSetAccountKey",
                LargeExchangeSetAccountName  = "LargeExchangeSetAccountName",
                LargeExchangeSetInstance     = 2,
                LargeExchangeSetSizeInMB     = 300,
                MediumExchangeSetAccountKey  = "MediumExchangeSetAccountKey",
                MediumExchangeSetAccountName = "MediumExchangeSetAccountName",
                MediumExchangeSetInstance    = 3,
                SmallExchangeSetAccountKey   = "SmallExchangeSetAccountKey",
                SmallExchangeSetAccountName  = "SmallExchangeSetAccountName",
                SmallExchangeSetInstance     = 2,
                SmallExchangeSetSizeInMB     = 50
            });

            fakeAzureMessageQueueHelper = A.Fake <IAzureMessageQueueHelper>();
            fakeLogger = A.Fake <ILogger <AzureBlobStorageService> >();
            fakeAzureBlobStorageClient    = A.Fake <IAzureBlobStorageClient>();
            fakeSmallExchangeSetInstance  = A.Fake <ISmallExchangeSetInstance>();
            fakeMediumExchangeSetInstance = A.Fake <IMediumExchangeSetInstance>();
            fakeLargeExchangeSetInstance  = A.Fake <ILargeExchangeSetInstance>();

            azureBlobStorageService = new AzureBlobStorageService(fakeScsStorageService, fakeStorageConfig,
                                                                  fakeAzureMessageQueueHelper, fakeLogger, fakeAzureBlobStorageClient, fakeSmallExchangeSetInstance,
                                                                  fakeMediumExchangeSetInstance, fakeLargeExchangeSetInstance);
        }
Exemplo n.º 2
0
 public AzureBlobStorageService(ISalesCatalogueStorageService scsStorageService, IOptions <EssFulfilmentStorageConfiguration> storageConfig,
                                IAzureMessageQueueHelper azureMessageQueueHelper, ILogger <AzureBlobStorageService> logger, IAzureBlobStorageClient azureBlobStorageClient,
                                ISmallExchangeSetInstance smallExchangeSetInstance, IMediumExchangeSetInstance mediumExchangeSetInstance,
                                ILargeExchangeSetInstance largeExchangeSetInstance)
 {
     this.scsStorageService       = scsStorageService;
     this.storageConfig           = storageConfig;
     this.azureMessageQueueHelper = azureMessageQueueHelper;
     this.logger = logger;
     this.azureBlobStorageClient    = azureBlobStorageClient;
     this.smallExchangeSetInstance  = smallExchangeSetInstance;
     this.mediumExchangeSetInstance = mediumExchangeSetInstance;
     this.largeExchangeSetInstance  = largeExchangeSetInstance;
 }
Exemplo n.º 3
0
 public void Setup()
 {
     smallExchangeSetInstance  = new SmallExchangeSetInstance();
     mediumExchangeSetInstance = new MediumExchangeSetInstance();
     largeExchangeSetInstance  = new LargeExchangeSetInstance();
 }