Ejemplo n.º 1
0
        public void ConstructorTest_Overload()
        {
            mAtlasDoc = new AtlasDocument("500", "500");
            //verify document and root are not null
            XmlDocument doc = mAtlasDoc.XMLDoc;

            Assert.IsNotNull(doc);
            Assert.IsNotNull(mAtlasDoc.RootNode);

            //verify width and height attributes
            Assert.AreEqual("500", mAtlasDoc.SheetWidth);
            Assert.AreEqual("500", mAtlasDoc.SheetHeight);
        }
Ejemplo n.º 2
0
        public void ClearAtlasTest()
        {
            mAtlasDoc = new AtlasDocument("500", "500");
            //add some sprite elems
            mAtlasDoc.AddSprite("0", "0", "0", "100", "100");
            mAtlasDoc.AddSprite("1", "0", "100", "100", "100");
            mAtlasDoc.AddSprite("2", "0", "200", "100", "100");

            //call clear
            mAtlasDoc.Clear();
            //verify group has no children
            XmlNode groupNode = mAtlasDoc.RootNode.FirstChild;

            Assert.AreEqual(0, groupNode.ChildNodes.Count);
        }
Ejemplo n.º 3
0
 public void TestInit()
 {
     mAtlasDoc = new AtlasDocument();
 }