System.Xml.Tests.TCWriteAttributes.writeAttributes_10 C# (CSharp) Method

writeAttributes_10() public method

public writeAttributes_10 ( ) : int
return int
        public int writeAttributes_10()
        {
            using (XmlWriter w = CreateWriter())
            {
                using (XmlReader xr = CreateReader("XmlReader.xml"))
                {
                    while (xr.Read())
                    {
                        if (xr.LocalName == "QuoteChar")
                        {
                            do { xr.Read(); } while (xr.LocalName != "node");
                            xr.MoveToFirstAttribute();
                            break;
                        }
                    }
                    w.WriteStartElement("Root");
                    w.WriteAttributes(xr, false);
                    w.WriteEndElement();
                }
            }
            return CompareReader("<Root a=\"b&quot;c\" />") ? TEST_PASS : TEST_FAIL;
        }