Esempio n. 1
0
		public async void ClientReturnsNullWithIncorrectUrl()
		{
			var client = new CurrencyClient();
			CurrencyClient.ClientUrl = "http://whatever.com/{0}";

			Currency res = await client.GetRates();

			Assert.IsNull(res, "the result should really be null");

		}
Esempio n. 2
0
		public async void ClientCanConnectAndGetResultsWithNZD()
		{
			var client = new CurrencyClient();

			Currency res = await client.GetRates();

			Assert.IsNotNull(res, "We shoud have got a result back");
			Assert.AreEqual("USD", res.BaseCurrency);
			Assert.Greater(res.Currencys.Count, 0, "should have more than 0 currencies");

		}