示例#1
0
        public void StripTcdlComponentPresentationTag_Success()
        {
            Publication  testPublication = (Publication)TestSession.GetObject(TestFixture.AutoTestParentWebDavUrl);
            TestTemplate testTemplate    = new TestTemplate(testPublication);

            string input1  = "<TCDL:ComponentPresentation a=\"1\">Test <tcdl>.</TCDL:ComponentPresentation>";
            string result1 = testTemplate.TestStripTcdlComponentPresentationTag(input1);

            Console.WriteLine(result1);

            string input2  = "<tcdl:ComponentPresentation a=\"1\">Test <tcdl>.</tcdl:ComponentPresentation>";
            string result2 = testTemplate.TestStripTcdlComponentPresentationTag(input2);

            Console.WriteLine(result2);

            Assert.AreEqual(input1, result1);
            Assert.AreEqual("Test <tcdl>.", result2);
        }