System.Xml.Tests.TCElement.element_13 C# (CSharp) Method

element_13() public method

public element_13 ( ) : int
return int
        public int element_13()
        {
            bool isAttr = (bool)CurVariation.Params[0];
            string exp = (string)CurVariation.Params[1];
            double a = 1;
            double b = 0;
            double c = 1;
            double d = -a * b / c;

            using (XmlWriter w = CreateWriter())
            {
                w.WriteStartElement("Root");
                if (isAttr) w.WriteStartAttribute("b");
                w.WriteValue(d);
                w.WriteEndElement();
            }
            return (CompareString(exp)) ? TEST_PASS : TEST_FAIL;
        }