public async Task SetAsyncUri_ReturnsValueFromAsyncTask() { DataPackage dataPackage = new DataPackage(); dataPackage.SetAsyncUri(async (formatId, deadline) => { await Task.Delay(200); return new Uri("http://www.example.org/"); }); DataPackageView dataPackageView = dataPackage.GetView(); Uri result = await dataPackageView.GetUriAsync(); Assert.AreEqual("http://www.example.org/", result.AbsoluteUri); }