Fix/integrationtests (#391)

* fixed the problem with parsing sql2017 version
This commit is contained in:
Leila Lali
2017-06-22 09:20:58 -07:00
committed by GitHub
parent af2ed84953
commit c28a97e6fa
9 changed files with 83 additions and 37 deletions

View File

@@ -828,17 +828,29 @@ GO";
/// </summary>
private void Cleanup(Location[] locations)
{
Uri fileUri = new Uri(locations[0].Uri);
if (File.Exists(fileUri.LocalPath))
try
{
try
string filePath = locations[0].Uri;
Uri fileUri = null;
if (Uri.IsWellFormedUriString(filePath, UriKind.Absolute))
{
File.Delete(fileUri.LocalPath);
fileUri = new Uri(filePath);
}
catch (Exception)
else
{
filePath = filePath.Replace("file:/", "file://");
if (Uri.IsWellFormedUriString(filePath, UriKind.Absolute))
{
fileUri = new Uri(filePath);
}
}
if (fileUri != null && File.Exists(fileUri.LocalPath))
{
File.Delete(fileUri.LocalPath);
}
}
catch (Exception)
{
}
}

View File

@@ -375,7 +375,7 @@ namespace Microsoft.SqlTools.ServiceLayer.IntegrationTests.ObjectExplorer
VerifyMetadata(child);
if (stringBuilder != null && child.NodeType != "Folder" && child.NodeType != "FileGroupFile")
{
stringBuilder.AppendLine($"NodeType: {child.NodeType} Label: {child.Label} SubType:{child.NodeSubType} Status:{child.NodeStatus}");
stringBuilder.Append($"NodeType: {child.NodeType} Label: {child.Label} SubType:{child.NodeSubType} Status:{child.NodeStatus}{Environment.NewLine}");
}
if (!verifySystemObjects && (child.Label == SR.SchemaHierarchy_SystemStoredProcedures ||
child.Label == SR.SchemaHierarchy_SystemViews ||