System.Xml.Tests.TC_SchemaSet_Reprocess.v4 C# (CSharp) Method

v4() private method

private v4 ( ) : void
return void
        public void v4()
        {
            XmlSchemaSet sc = new XmlSchemaSet();
            XmlSchema Schema1 = sc.Add(null, TestData._XsdAuthor);
            CError.Compare(sc.Count, 1, "AddCount");
            CError.Compare(sc.Contains(Schema1), true, "AddContains");
            CError.Compare(sc.IsCompiled, false, "AddIsCompiled");

            sc.Compile();
            CError.Compare(sc.Count, 1, "Compile Count");
            CError.Compare(sc.Contains(Schema1), true, "CompileContains");
            //edit
            XmlSchemaElement elementDog = new XmlSchemaElement();
            Schema1.Items.Add(elementDog);
            elementDog.Name = "dog";
            elementDog.SchemaTypeName = new XmlQualifiedName("string", "http://www.w3.org/2001/XMLSchema");

            sc.Reprocess(Schema1);
            CError.Compare(sc.Count, 1, "ReprocessCount");
            CError.Compare(sc.Contains(Schema1), true, "ReprocessContains");
            CError.Compare(sc.IsCompiled, false, "ReprocessIsCompiled");

            sc.Compile();
            CError.Compare(sc.Count, 1, "Compile");
            CError.Compare(sc.IsCompiled, true, "CompileIsCompiled");
            CError.Compare(Schema1.IsCompiled, true, "CompileIsCompiled on SOM");
            CError.Compare(sc.Contains(Schema1), true, "CompileContains");

            return;
        }