Exemplo n.º 1
0
        private void IsNotSubtreeTest(ISubtreeChecker subtreeChecker)
        {
            BinaryTreeNode t1     = CreateMainTree();
            BinaryTreeNode t2     = CreateNotSubtree();
            bool           result = subtreeChecker.IsSubtree(t1, t2);

            Assert.AreEqual(false, result);
        }
Exemplo n.º 2
0
 private void RunExceptionTest <TException>(BinaryTreeNode t1, BinaryTreeNode t2, ISubtreeChecker subtreeChecker) where TException : Exception
 {
     try
     {
         subtreeChecker.IsSubtree(t1, t2);
         Assert.Fail();
     }
     catch (TException)
     {
     }
 }