Axiom.UnitTests.Core.SceneNodeTests.TestChildSceneNodeDestruction C# (CSharp) Method

TestChildSceneNodeDestruction() private method

private TestChildSceneNodeDestruction ( ) : void
return void
        public void TestChildSceneNodeDestruction()
        {
            SceneManager sceneManager = new StubSceneManager( "Manager under test" );
            SceneNode node = sceneManager.CreateSceneNode( "testNode" );
            SceneNode childNode = node.CreateChildSceneNode( "childNode" );

            Assert.IsTrue( ManagerContainsNode( sceneManager, childNode ), "A child node was created but not added to the scene graph." );

            node.RemoveAndDestroyChild( childNode );

            Assert.IsFalse( ManagerContainsNode( sceneManager, childNode ), "A child node was destroyed but not removed from the scene graph." );
        }