private static void PrintRatesBtc() { var cryptoCurrencies = new CryptoCompare(); var coinList = cryptoCurrencies.GetCoinList(); var pricing = new List <string> { $"{DateTime.Now}", $"{coinList.Data.BTC.Name} : {cryptoCurrencies.GetGetPrice(coinList.Data.BTC.Name, Constants.Btc).Data.First().Price}", $"{coinList.Data.DSH.Name} : {cryptoCurrencies.GetGetPrice(coinList.Data.DSH.Name, Constants.Btc).Data.First().Price}", $"{coinList.Data.ETH.Name} : {cryptoCurrencies.GetGetPrice(coinList.Data.ETH.Name, Constants.Btc).Data.First().Price}", $"{coinList.Data.LTC.Name} : {cryptoCurrencies.GetGetPrice(coinList.Data.LTC.Name, Constants.Btc).Data.First().Price}", $"{coinList.Data.ZEC.Name} : {cryptoCurrencies.GetGetPrice(coinList.Data.ZEC.Name, Constants.Btc).Data.First().Price}" }; WriteToFile(pricing, "pricingBtc.txt"); }
public void WhenIMakeACallForPricingForEthInUSD_ThenIShouldGetBackPricing() { var testClass = new CryptoCompare(); var response = testClass.GetGetPrice("ETH", "USD"); Assert.NotNull(response); Assert.NotNull(response.Data); Assert.NotNull(response.Data.First().Price); }