Esempio n. 1
0
        public void WriteCustomAttributeChoiceLabelUsingAttributeDefinition()
        {
            Post post = new Post(_ctx.Listen360, TestUtil.GetElementForXml(_postXml));
            ICustomAttributeDefinition attrDef = new FakeCustomAttributeDefinition();

            post[attrDef] = "News";
            Assert.AreEqual("News", post[attrDef]);
        }
Esempio n. 2
0
        public void ReadCustomAttributeChoiceLabelUsingAttributeDefinition()
        {
            Post post = new Post(_ctx.Listen360, TestUtil.GetElementForXml(_postXml));
            ICustomAttributeDefinition attrDef = new FakeCustomAttributeDefinition();

            Assert.AreEqual(1, attrDef.Ordinal);
            Assert.NotNull(post[attrDef]);
            Assert.AreEqual("Article", post[attrDef]);
        }