コード例 #1
0
        public void OneAttribute(IAttribute attribute)
        {
            // arrange
            var concept = new Concept();

            concept.WithAttribute(attribute);

            // act
            var xml      = new Semantics.Xml.Concept(concept);
            var restored = xml.Load();

            // assert
            Assert.AreSame(attribute, restored.Attributes.Single());
        }
コード例 #2
0
        public void AllAttributes()
        {
            // arrange
            var concept = new Concept();

            foreach (var attribute in getAllAttributes())
            {
                concept.WithAttribute(attribute);
            }

            // act
            var xml      = new Semantics.Xml.Concept(concept);
            var restored = xml.Load();

            // assert
            Assert.IsTrue(restored.Attributes.SequenceEqual(concept.Attributes));
        }