System.Xml.Tests.TCFullEndElement.TCCData.CData_9 C# (CSharp) Méthode

CData_9() public méthode

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