public ForexServiceInstance(
     ICurrencyLayerClient currencyLayerClient,
     IOptions <ForexServiceOptions> options)
 {
     this._currencyLayerClient = currencyLayerClient ?? throw new ArgumentNullException(nameof(currencyLayerClient));
     this._options             = options.Value ?? throw new ArgumentNullException(nameof(options));
 }
Beispiel #2
0
        public void Setup()
        {
            var client         = new HttpClient();
            var httpClientMock = new Mock <IHttpClientFactory>();

            httpClientMock.Setup(h => h.CreateClient(It.IsAny <string>())).Returns(client);
            currencyClient = new CurrencyLayerClient(httpClientMock.Object);
        }