コード例 #1
0
        public void Properties()
        {
            Algorithm a = new Algorithm();

            mtg tree = new mtg();
            int root = tree.root;

            int root1 = tree.AddComponent(root);
            int vid   = a.RandomTree(tree, root1, 18);

            List <int> childAndComplex = tree.AddChildAndComplex(vid);

            vid = a.RandomTree(tree, childAndComplex[0], 18);

            List <int> childAndComplex2 = tree.AddChildAndComplex(vid);

            vid = a.RandomTree(tree, childAndComplex2[0], 18);

            Assert.IsTrue(tree.PropertyNames().Contains("Edge_Type"));
            Assert.AreEqual(18 * 3, tree.Property("Edge_Type").Count);
        }