Support "SQL" settings in addition to MSSQL (#398)

* Support "SQL" settings in addition to MSSQL
- Handles having 2 separate configuration definitions and merging / treating them as 1 throughout the app
- If a settings group such as Intellisense is defined on mssql, it will override any generic SQL properties
- Retains backwards compatibility with existing settings.
This commit is contained in:
Kevin Cunnane
2017-06-29 17:03:11 -07:00
committed by GitHub
parent 8f5b5b14ca
commit 2a5ae06f12
8 changed files with 261 additions and 66 deletions

View File

@@ -31,11 +31,17 @@ namespace Microsoft.SqlTools.ServiceLayer.UnitTests.QueryExecution
[Fact]
public void ValidateSettingsParsedFromJson()
{
ValidateSettings("mssql");
ValidateSettings("sql");
}
private static void ValidateSettings(string settingsPropertyName)
{
// NOTE: Only testing displayBitAsNumber for now because it is the only one piped through
const string settingsJson = @"{"
string settingsJson = @"{"
+ @"""params"": {"
+ @"""mssql"": {"
+ @""""+settingsPropertyName+@""": {"
+ @"""query"": {"
+ @"displayBitAsNumber: false"
+ @"}"