Testing property set by async method
问题 I try to test a class with NUnit that contains async methods. I don't know how to do it in a correct way. I have a class with that looks like this: public class EditorViewModel:INotifyPropertyChanged { public void SetIdentifier(string identifier) { CalcContentAsync(); } private async void CalcContentAsync() { await SetContentAsync(); DoSomething(); } private async Task SetContentAsync() { Content = await Task.Run<object>(() => CalculateContent()); RaisePropertyChanged("Content"); } public