mirror of
https://github.com/ckaczor/sqltoolsservice.git
synced 2026-01-21 01:25:42 -05:00
Update Keywords list to include most tokens (#244)
- Fixes https://github.com/Microsoft/vscode-mssql/issues/705 - Updated the keyword list to include most common keyword ranges and added test to cover top 10 missing keywords - Fixed a bug in TestUtilities.cs where text range was not defined correctly.
This commit is contained in:
@@ -0,0 +1,32 @@
|
||||
//
|
||||
// Copyright (c) Microsoft. All rights reserved.
|
||||
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
|
||||
//
|
||||
|
||||
using Microsoft.SqlTools.ServiceLayer.Formatter;
|
||||
using Xunit;
|
||||
|
||||
namespace Microsoft.SqlTools.ServiceLayer.Test.Formatter
|
||||
{
|
||||
public class GeneralFormatterTests : FormatterUnitTestsBase
|
||||
{
|
||||
[Fact]
|
||||
public void KeywordCaseConversionUppercase()
|
||||
{
|
||||
LoadAndFormatAndCompare("KeywordCaseConversion",
|
||||
GetInputFile("KeywordCaseConversion.sql"),
|
||||
GetBaselineFile("KeywordCaseConversion_Uppercase.sql"),
|
||||
new FormatOptions() { KeywordCasing = CasingOptions.Uppercase },
|
||||
verifyFormat: true);
|
||||
}
|
||||
[Fact]
|
||||
public void KeywordCaseConversionLowercase()
|
||||
{
|
||||
LoadAndFormatAndCompare("KeywordCaseConversion",
|
||||
GetInputFile("KeywordCaseConversion.sql"),
|
||||
GetBaselineFile("KeywordCaseConversion_Lowercase.sql"),
|
||||
new FormatOptions() { KeywordCasing = CasingOptions.Lowercase },
|
||||
verifyFormat: true);
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user