System.Xml.Tests.TCFullEndElement.TCPI.pi_13 C# (CSharp) Méthode

pi_13() public méthode

public pi_13 ( ) : int
Résultat int
            public int pi_13()
            {
                using (XmlWriter w = CreateWriter())
                {
                    try
                    {
                        w.WriteStartElement("Root");
                        w.WriteProcessingInstruction("pi", "\uD812");
                        w.WriteEndElement();
                    }
                    catch (ArgumentException e)
                    {
                        CError.WriteLineIgnore("Exception: " + e.ToString());
                        CheckErrorState(w.WriteState);
                        return TEST_PASS;
                    }
                }
                CError.WriteLine("Did not throw exception");
                return TEST_FAIL;
            }
        }