private IExchangeRateService GetExchangeRateProviderWithInvalidConfig() { var configStore = new DummyConfigurationStore(); configStore.Configuration = new System.Collections.Specialized.NameValueCollection(); configStore.Configuration.Add(Constants.NumberOfSlots, "abc"); return(new PerodicExchangeRateService(new RefreshingDBRepository(), configStore)); }
private PerodicExchangeRateService GetRefreshingExchangeRateProvider() { var configStore = new DummyConfigurationStore(); configStore.Configuration = new System.Collections.Specialized.NameValueCollection(); configStore.Configuration.Add(Constants.NumberOfSlots, (24 * 60).ToString()); return(new PerodicExchangeRateService(new RefreshingDBRepository(), configStore, 1440)); }
DummyConfigurationStore GetConfigStore(string dynamoDBServiceUrl, string awsSecretKey, string awsAPIKey) { var configStore = new DummyConfigurationStore(); configStore.Configuration = new System.Collections.Specialized.NameValueCollection(); configStore.Configuration.Add(Constants.DynamoDBServiceUrl, dynamoDBServiceUrl); configStore.Configuration.Add(Constants.AWSSecretKey, awsSecretKey); configStore.Configuration.Add(Constants.AWSAccessKey, awsAPIKey); return(configStore); }