public void TestCascadeElements() { var cascaded = XmlXsd.Cascade(new schema() { element = { new element(new topLevelElement() { name = "testingElementThatShouldNotBeIn" }) } }); Assert.IsTrue(XmlXsd.element.Count == 0); Assert.IsTrue(cascaded.element.Count == 1); }
public void TestCascadeAttributes() { Assert.IsTrue(XmlXsd.attribute.Count == 4); var cascaded = XmlXsd.Cascade(new schema() { attribute = { new attribute(new topLevelAttribute() { name = "testingAttr" }) } }); // remains unchanged Assert.IsTrue(XmlXsd.attribute.Count == 4); Assert.IsTrue(cascaded.attribute.Count == 5); }