Exemple #1
0
        public void GetParent()
        {
            GameObject parent = new GameObject();
            GameObject child  = new GameObject();

            SceneNodeView.SetName(parent, "parent");
            SceneNodeView.SetName(child, "child");
            SceneNodeView.AddChild(parent, child);
            Assert.AreEqual("parent", SceneNodeView.GetName(
                                SceneNodeView.GetParent(child)));
            Assert.AreEqual(parent,
                            SceneNodeView.GetParent(child));
            Object.DestroyImmediate(parent);
            Object.DestroyImmediate(child);
        }