public void SimpleMultiThreadTestTrackerTest() { // Assert.Fail("Need to write this test conforming to new API - TargetedDelegatedOperation should not be public (or even not exist)"); HistoryTracker globalTracker = new HistoryTracker(); SlowSimpleTrackedObject sto1 = new SlowSimpleTrackedObject(); SlowSimpleTrackedObject sto2 = new SlowSimpleTrackedObject(); globalTracker .Track((ITrackedObject)sto1) .Track((ITrackedObject)sto2); globalTracker.AddOperation(new DelegateOperation( () => { Thread.Sleep(100); Thread.Yield(); Thread.Sleep(100); }, () => { Thread.Sleep(100); Thread.Yield(); Thread.Sleep(100); })); Task.Factory.StartNew( () => { globalTracker.Undo(); globalTracker.Undo(); globalTracker.Undo(); }); sto1.ChangeValues(1, 2, 3); sto2.ChangeValues(2, 3, 4); }