Update Microsoft.Data.SqlClient to v5.0.1 (#1708)

This commit is contained in:
Cheena Malhotra
2022-10-24 20:10:04 -07:00
committed by GitHub
parent 3be806ddce
commit c0f8482e26
30 changed files with 416 additions and 313 deletions

View File

@@ -16,9 +16,9 @@ namespace Microsoft.SqlTools.ServiceLayer.Test.Common
public class ConnectionSetting
{
[JsonProperty("mssql.connections")]
public List<InstanceInfo> Connections { get; set; }
public List<InstanceInfo>? Connections { get; set; }
public InstanceInfo GetConnectionProfile(string profileName, string serverName)
public InstanceInfo? GetConnectionProfile(string profileName, string serverName)
{
if (!string.IsNullOrEmpty(profileName) && Connections != null)
{
@@ -28,7 +28,7 @@ namespace Microsoft.SqlTools.ServiceLayer.Test.Common
return byProfileName;
}
}
return Connections.FirstOrDefault(x => x.ServerName == serverName);
return Connections?.FirstOrDefault(x => x.ServerName == serverName);
}
}
@@ -47,23 +47,29 @@ namespace Microsoft.SqlTools.ServiceLayer.Test.Common
public string ServerName { get; set; }
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public string Database { get; set; }
public string? Database { get; set; }
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public string User { get; set; }
public string? User { get; set; }
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public string Password { get; set; }
public string? Password { get; set; }
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public string ProfileName { get; set; }
public string? ProfileName { get; set; }
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public string? Encrypt { get; set; }
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public string? HostNameInCertificate { get; set; }
public TestServerType ServerType { get; set; }
public AuthenticationType AuthenticationType { get; set; }
[JsonProperty(NullValueHandling = NullValueHandling.Ignore)]
public string RemoteSharePath { get; set; }
public string? RemoteSharePath { get; set; }
public int ConnectTimeout { get; set; }