Indicates that the comment tags should be ignored during the comparison.

Namespace:  MbUnit.Framework
Assembly:  MbUnit (in MbUnit.dll) Version: 3.3.0.0 (3.3.610.0)

Syntax

C#
public CustomXmlOptions IgnoreComments { get; }
Visual Basic (Declaration)
Public ReadOnly Property IgnoreComments As CustomXmlOptions

Examples

CopyC#
[Test]
public void MyXmlTest()
{
    string expected = "<Animal name='Peary Caribou'><!-- Living in herds numbering less than 20. --></Animal>" +;
    string actual = "<Animal name='Peary Caribou'><!-- Unknown surviving number. --></Animal>" +;
    Assert.Xml.AreEqual(expected, actual, XmlOptions.Custom.IgnoreComments); // Pass!
}

See Also