public static void BindsWithoutError(object viewModel, Func <Window> process) { using (AssertNoBindingErrorsTraceListener.Start()) { Window window = process(); window.DataContext = viewModel; window.Show(); // force binding } }
public DisposableToken(AssertNoBindingErrorsTraceListener listener) { this.listener = listener; }
public static IDisposable Start(SourceLevels level = SourceLevels.Warning) { var listener = new AssertNoBindingErrorsTraceListener(level); return(new DisposableToken(listener)); }
public static IDisposable Start(SourceLevels level = SourceLevels.Warning) { var listener = new AssertNoBindingErrorsTraceListener(level); return new DisposableToken(listener); }