From 3d8eefa685fe2b3c667be4fd111f14b9609dfbba Mon Sep 17 00:00:00 2001 From: llali Date: Mon, 7 Nov 2016 13:19:28 -0800 Subject: [PATCH] Fixed a failed test --- .../ServiceHost/ScriptFileTests.cs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/test/Microsoft.SqlTools.ServiceLayer.Test/ServiceHost/ScriptFileTests.cs b/test/Microsoft.SqlTools.ServiceLayer.Test/ServiceHost/ScriptFileTests.cs index b3efd939..817f3328 100644 --- a/test/Microsoft.SqlTools.ServiceLayer.Test/ServiceHost/ScriptFileTests.cs +++ b/test/Microsoft.SqlTools.ServiceLayer.Test/ServiceHost/ScriptFileTests.cs @@ -99,7 +99,8 @@ namespace Microsoft.SqlTools.ServiceLayer.Test.ServiceHost { ScriptFile scriptFile = GetTestScriptFile(); int offset = scriptFile.GetOffsetAtPosition(2, 5); - Assert.True(offset == 37, "Offset is at expected location"); + int expected = 35 + Environment.NewLine.Length; + Assert.True(offset == expected, "Offset is at expected location"); BufferPosition position = scriptFile.GetPositionAtOffset(offset); Assert.True(position.Line == 2 && position.Column == 5, "Position is at expected location");