예제 #1
0
 public void CountTreesTheory(int TestNumber)
 {
     Assert.Equal(14, BinaryTree <Int32> .CountTrees(TestNumber));
 }
예제 #2
0
 /// <summary>
 /// SameTree Compares the receiver to another tree to
 /// see if they are structurally identical.
 /// </summary>
 public bool SameTree(BinaryTree <T> other)
 {
     return(SameTree(root, other.root));
 }
예제 #3
0
 /// <summary>
 /// InitTree method sets up _bTree with simplest test case, using elements 1, 2, 3.
 /// This method is reused to initialize the _bTree variable again for each test.
 /// </summary>
 private void InitTree()
 {
     _bTree = new BinaryTree <Int32>();
     _bTree.Build123c(_varOne, _varTwo, _varThree);
 }