public async void TestGetUnderwriters() { IProgramService programService = new ProgramService(); var task = Task.Factory.StartNew(() => programService.GetUnderwritersAsync()); Dictionary <int, string> uwDict = new Dictionary <int, string>(); var uwDictTask = await task; await uwDictTask.ContinueWith(e => { if (e.IsCompleted) { Console.Out.WriteLine("Number of UWs: " + e.Result.Count); Assert.Greater(e.Result.Count, 0); } }); Console.Out.WriteLine("Waiting for results"); }