public void WriteColumnFormatsXmlIconFormattingRuleNodeTest( )
        {
            #region Setup

            List <ColumnFormatting> originalColumnFormats = CreateTestIconFormattingRules( );

            #endregion

            #region Test

            var writerText = new StringBuilder( );
            using (XmlWriter writer = XmlWriter.Create(writerText, new XmlWriterSettings
            {
                OmitXmlDeclaration = true
            }))
            {
                FormattingRuleHelper.WriteColumnFormatsXml(originalColumnFormats, writer);
            }
            writerText.Insert(0, "<gridReportDataView>");
            writerText.Append("</gridReportDataView>");

            #endregion

            #region Validate

            var document = new XmlDocument( );
            document.LoadXml(writerText.ToString( ));

            IList <ColumnFormatting> newColumnFormats = FormattingRuleHelper.ReadColumnFormatsXml(document.DocumentElement);

            CompareColumnFormats(originalColumnFormats, newColumnFormats);

            #endregion
        }
        public void WriteColumnFormatsXmlNullColumnFormatsTest( )
        {
            var       writerText = new StringBuilder( );
            XmlWriter writer     = XmlWriter.Create(writerText);

            FormattingRuleHelper.WriteColumnFormatsXml(null, writer);
        }
        public void WriteColumnFormatsXmlNullWriterTest( )
        {
            var columnFormats = new List <ColumnFormatting>( );

            FormattingRuleHelper.WriteColumnFormatsXml(columnFormats, null);
        }