public void VisitPairCountTest() { Tree<string> tested = new Tree<string>(); TreeNode<string> root = tested.SetRoot("A"); root.AddChild("B"); root.AddChild("C"); int actualCount = 0; tested.VisitPairs((x,y) => actualCount++); int expectedCount = 2; Assert.AreEqual(expectedCount, actualCount); }