Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/mono.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexander Köplinger <alex.koeplinger@outlook.com>2017-01-28 04:23:38 +0300
committerAlexander Köplinger <alex.koeplinger@outlook.com>2017-01-28 04:25:55 +0300
commitd61e7aca9a4c858c30d6512a7dc8a86f307683a7 (patch)
tree0d3fab9c006247feda1b6e1633b895bc0f6e43a1 /mcs/class/System.XML
parent9bee02a3ff15045afbbd8a2f9d96830acb82d7e4 (diff)
[bcl] Update tests that failed when .cs file contained CRLF
Most of them used multiline C# string literals which means they contained the line ending character of the file. Updated to make the tests resilient to having CRLF instead of LF. Some of the mcs tests used a checksum to compare files, ensured those are checked out using LF.
Diffstat (limited to 'mcs/class/System.XML')
-rw-r--r--mcs/class/System.XML/Test/System.Xml.XPath/XPathNavigatorCommonTests.cs2
-rw-r--r--mcs/class/System.XML/Test/System.Xml.XPath/XPathNavigatorTests.cs2
-rw-r--r--mcs/class/System.XML/Test/System.Xml.Xsl/XslTransformTests.cs2
-rw-r--r--mcs/class/System.XML/Test/System.Xml/XmlWriterSettingsTests.cs2
4 files changed, 4 insertions, 4 deletions
diff --git a/mcs/class/System.XML/Test/System.Xml.XPath/XPathNavigatorCommonTests.cs b/mcs/class/System.XML/Test/System.Xml.XPath/XPathNavigatorCommonTests.cs
index fd31e829cb3..51959ee6175 100644
--- a/mcs/class/System.XML/Test/System.Xml.XPath/XPathNavigatorCommonTests.cs
+++ b/mcs/class/System.XML/Test/System.Xml.XPath/XPathNavigatorCommonTests.cs
@@ -446,7 +446,7 @@ namespace MonoTests.System.Xml
string ret = @"<one>
<two>Some data.</two>
</one>";
- Assert.AreEqual (ret, nav.OuterXml.Replace ("\r\n", "\n"), "#1");
+ Assert.AreEqual (ret.Replace ("\r\n", "\n"), nav.OuterXml.Replace ("\r\n", "\n"), "#1");
}
[Test]
diff --git a/mcs/class/System.XML/Test/System.Xml.XPath/XPathNavigatorTests.cs b/mcs/class/System.XML/Test/System.Xml.XPath/XPathNavigatorTests.cs
index 7bb0b34e181..d436633cbdd 100644
--- a/mcs/class/System.XML/Test/System.Xml.XPath/XPathNavigatorTests.cs
+++ b/mcs/class/System.XML/Test/System.Xml.XPath/XPathNavigatorTests.cs
@@ -685,7 +685,7 @@ namespace MonoTests.System.Xml
</child1>
<child2 />
<child3 />";
- Assert.AreEqual (result, n.OuterXml.Replace ("\r\n", "\n"), "#1");
+ Assert.AreEqual (result.Replace ("\r\n", "\n"), n.OuterXml.Replace ("\r\n", "\n"), "#1");
}
[Test] // bug #376191
diff --git a/mcs/class/System.XML/Test/System.Xml.Xsl/XslTransformTests.cs b/mcs/class/System.XML/Test/System.Xml.Xsl/XslTransformTests.cs
index 1d5b3ab3932..d85ff8afccf 100644
--- a/mcs/class/System.XML/Test/System.Xml.Xsl/XslTransformTests.cs
+++ b/mcs/class/System.XML/Test/System.Xml.Xsl/XslTransformTests.cs
@@ -388,7 +388,7 @@ xmlns:xsl='http://www.w3.org/1999/XSL/Transform' xmlns:msxsl='urn:schemas-micros
StringWriter sw_raw = new StringWriter ();
t.Transform (d, null, sw_raw);
- Assert.AreEqual (ref_out, sw_raw.ToString ().Replace ("\r\n", "\n"));
+ Assert.AreEqual (ref_out.Replace ("\r\n", "\n"), sw_raw.ToString ().Replace ("\r\n", "\n"));
}
// http://support.microsoft.com/default.aspx?scid=kb;en-us;829014
diff --git a/mcs/class/System.XML/Test/System.Xml/XmlWriterSettingsTests.cs b/mcs/class/System.XML/Test/System.Xml/XmlWriterSettingsTests.cs
index 3ee725dff25..ed8509221fc 100644
--- a/mcs/class/System.XML/Test/System.Xml/XmlWriterSettingsTests.cs
+++ b/mcs/class/System.XML/Test/System.Xml/XmlWriterSettingsTests.cs
@@ -303,7 +303,7 @@ namespace MonoTests.System.Xml
<!--AAA-->
<root />";
- Assert.AreEqual (xml, sw.ToString ().Replace ("\r\n", "\n"), "#1");
+ Assert.AreEqual (xml.Replace ("\r\n", "\n"), sw.ToString ().Replace ("\r\n", "\n"), "#1");
}
[Test]