Beispiel #1
0
        public void TestsWithDeserializedObject()
        {
            var response = Request.RestRequest("https://api.exchangeratesapi.io/", "2010-01-14", "GET");
            CurrencyRateByDate ratesObject = CurrencyRateByDate.FromJson(response.Content);

            Assert.Equal("2010-01-14", ratesObject.Date);
            Assert.Equal(1.4942, ratesObject.Rates["CAD"]);
        }
 public static string ToJson(this CurrencyRateByDate self) => JsonConvert.SerializeObject(self, AAPExampleTests.Converter.Settings);