示例#1
0
        public async Task CalculateDistance_ReturnValue()
        {
            ISSTrackerApi api = new ISSTrackerApi();
            await api.AddRecord();

            await api.AddRecord();

            Assert.AreNotEqual(0, api.CalculateDistanceFromAllRecords());
        }
示例#2
0
        public async Task AddRecord_CorrectRecordAdded()
        {
            ISSTrackerApi api = new ISSTrackerApi();
            await api.AddRecord();

            Assert.AreEqual(1, api.RecordCount());
        }
示例#3
0
        public void AddRecord_NoConnection_Throws()
        {
            ISSTrackerApi api = new ISSTrackerApi();

            Assert.ThrowsAsync <HttpRequestException>(async() => await api.AddRecord());
        }