Browse Source

Normalize line ending in debug tests (just in case that the files on disk use linux line endings)

pull/1/head
David Srbecký 15 years ago
parent
commit
4116a1a479
  1. 2
      src/AddIns/Debugger/Debugger.Tests/DebuggerTestsBase.cs

2
src/AddIns/Debugger/Debugger.Tests/DebuggerTestsBase.cs

@ -145,6 +145,8 @@ namespace Debugger.Tests @@ -145,6 +145,8 @@ namespace Debugger.Tests
string actualXml = new StreamReader(newXmlStream).ReadToEnd() + "\r\n";
string sourceCode = GetResource(testName);
// Normalize the line endings
sourceCode = sourceCode.Replace("\r\n", "\n").Replace("\n", "\r\n");
int startIndex = sourceCode.IndexOf(startMark);
int endIndex = sourceCode.IndexOf(endMark);
if (startIndex == -1 || endIndex == -1) {

Loading…
Cancel
Save