diff options
Diffstat (limited to 'mcs/class/System.XML/Test/System.Xml/XmlReaderSettingsTests.cs')
-rw-r--r-- | mcs/class/System.XML/Test/System.Xml/XmlReaderSettingsTests.cs | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/mcs/class/System.XML/Test/System.Xml/XmlReaderSettingsTests.cs b/mcs/class/System.XML/Test/System.Xml/XmlReaderSettingsTests.cs index 768cd5671da..2b20f06e971 100644 --- a/mcs/class/System.XML/Test/System.Xml/XmlReaderSettingsTests.cs +++ b/mcs/class/System.XML/Test/System.Xml/XmlReaderSettingsTests.cs @@ -14,7 +14,7 @@ using System.Text; using System.Xml; using System.Xml.Schema; using NUnit.Framework; - +using System.Reflection; using ValidationFlags = System.Xml.Schema.XmlSchemaValidationFlags; using AssertType = NUnit.Framework.Assert; @@ -443,5 +443,15 @@ namespace MonoTests.System.Xml var r2 = XmlReader.Create (r, c); Assert.IsTrue (r2.Settings.Async); } + + [Test] + public void LegacyXmlSettingsAreDisabled () + { + // Make sure LegacyXmlSettings are always disabled on Mono + // https://bugzilla.xamarin.com/show_bug.cgi?id=60621 + var enableLegacyXmlSettingsMethod = typeof(XmlReaderSettings).GetMethod ("EnableLegacyXmlSettings", + BindingFlags.NonPublic | BindingFlags.Static); + Assert.IsFalse ((bool) enableLegacyXmlSettingsMethod.Invoke (null, null)); + } } } |