public async Task SetAsyncText_ReturnsValueFromAsyncTask() { DataPackage dataPackage = new DataPackage(); dataPackage.SetAsyncText(async (formatId, deadline) => { await Task.Delay(200); return "Test text"; }); DataPackageView dataPackageView = dataPackage.GetView(); string result = await dataPackageView.GetTextAsync(); Assert.AreEqual("Test text", result); }