public void TestRoot() { SparrowSharpApp.Start(12, 12, typeof(Sprite)); Sprite root = new Sprite(); Sprite child = new Sprite(); Sprite grandChild = new Sprite(); root.AddChild(child); child.AddChild(grandChild); Assert.AreEqual(root, grandChild.Root, "Wrong root " + grandChild.Root); SparrowSharpApp.Stage.AddChild(root); Assert.AreEqual(SparrowSharpApp.Stage, grandChild.Root, "Wrong root " + grandChild.Root); SparrowSharpApp.Stage.RemoveAllChildren(); SparrowSharpApp.Destroy(); }
protected void TearDown() { testRoot.RemoveAllChildren(); SparrowSharpApp.Destroy(); }