コード例 #1
0
        public void FbxObject_Create_EmptyNamespace()
        {
            // given:
            var obj = new FbxObject("asdf");

            // then:
            Assert.AreEqual("", obj.GetNameSpaceOnly());
        }
コード例 #2
0
        public void FbxObject_SetNameSpace_SetsNamespace()
        {
            // given:
            var obj = new FbxObject("asdf");

            // when:
            obj.SetNameSpace("qwer");

            // then:
            Assert.AreEqual("qwer", obj.GetNameSpaceOnly());
        }
コード例 #3
0
        public void FbxObject_SetNameSpaceAndGetNameWithoutNameSpacePrefix_FirstCharacterIsNotMissing()
        {
            // given:
            var obj = new FbxObject("asdf");

            obj.SetNameSpace("qwer");

            // require:
            Assert.AreEqual("asdf", obj.GetName());
            Assert.AreEqual("qwer", obj.GetNameSpaceOnly());

            // then:
            Assert.AreEqual("asdf", obj.GetNameWithoutNameSpacePrefix());
        }
コード例 #4
0
        public void FbxObject_SetNameSpaceAndGetNameWithoutNameSpacePrefix_IncludesNamespace()
        {
            // given:
            var obj = new FbxObject("asdf");

            obj.SetNameSpace("qwer");

            // require:
            Assert.AreEqual("asdf", obj.GetName());
            Assert.AreEqual("qwer", obj.GetNameSpaceOnly());

            // then:
            Assert.AreEqual("asdf", obj.GetNameWithNameSpacePrefix());
        }
コード例 #5
0
        public void FbxObject_SetNameSpaceThenSetInitialName_FirstCharacterIsStillMissing()
        {
            // given:
            var obj = new FbxObject("asdf");

            obj.SetNameSpace("qwer");

            // require:
            Assert.AreEqual("asdf", obj.GetName());
            Assert.AreEqual("qwer", obj.GetNameSpaceOnly());

            // when:
            obj.SetInitialName("zxcv");

            // then:
            Assert.AreEqual("zxcv", obj.GetInitialName());
            Assert.AreEqual("zxcv", obj.GetName());
            Assert.AreEqual("xcv", obj.GetNameOnly());
        }