public void DependsOn_ReactiveBrotherSetToNewValueThenBackToNullAndAgeChangedAfterward_DoesNotTriggerAnyDependsOnMethods() { ReactivePerson ReactiveBrother = new ReactivePerson(); _target.ReactiveBrother = ReactiveBrother; _target.ReactiveBrother = null; ReactiveBrother.Age = 10; Assert.AreEqual(2, _target.OnReactiveBrotherChangedCalledCount); Assert.AreEqual(2, _target.OnReactiveBrotherAgeChangedCalledCount); }
public void DependsOn_TwoLevelTreeWithVaryingTypes_FiresUpdatesProperly() { var root = new ReactiveType0(); var child = new ReactiveType1(); var person = new ReactivePerson(); root.ChildReactiveType1 = child; child.ChildReactivePerson = person; person.Name = "Jim"; //child.Name = "Bob"; Assert.AreEqual(3, root.Updates); }
public void Initialize() { _target = new ReactivePerson(); }