Skip to content

Commit 3c129e8

Browse files
committed
fix test
1 parent dc7774a commit 3c129e8

File tree

3 files changed

+26
-17
lines changed

3 files changed

+26
-17
lines changed

internal/ls/completions.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4376,7 +4376,6 @@ func isSolelyIdentifierDefinitionLocation(
43764376
// If `contextToken !== previousToken`, this is `class C ex/**/`, `interface I ex/**/` or `<T ex/**/>`.
43774377
!((ast.IsClassLike(parent) || ast.IsInterfaceDeclaration(parent) || ast.IsTypeParameterDeclaration(parent)) &&
43784378
(contextToken != previousToken || position > previousToken.End()))
4379-
43804379
}
43814380

43824381
func isVariableDeclarationListButNotTypeArgument(node *ast.Node, file *ast.SourceFile, typeChecker *checker.Checker) bool {

internal/ls/completions_test.go

Lines changed: 25 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1895,26 +1895,36 @@ var v10 = /reg/*inRegExp1*/ex/;`,
18951895
},
18961896
expectedResult: map[string]*testCaseResult{
18971897
"openString1": {
1898-
list: &lsproto.CompletionList{
1899-
IsIncomplete: false,
1900-
ItemDefaults: itemDefaults,
1901-
Items: []*lsproto.CompletionItem{},
1902-
},
1898+
list: nil,
19031899
},
19041900
"openString2": {
1905-
list: &lsproto.CompletionList{
1906-
IsIncomplete: false,
1907-
ItemDefaults: itemDefaults,
1908-
Items: []*lsproto.CompletionItem{},
1909-
},
1901+
list: nil,
19101902
},
19111903
"openString3": {
1912-
list: &lsproto.CompletionList{
1913-
IsIncomplete: false,
1914-
ItemDefaults: itemDefaults,
1915-
Items: []*lsproto.CompletionItem{},
1916-
},
1904+
list: nil,
19171905
},
1906+
// !!! isInComment
1907+
// "inComment1": {
1908+
// list: nil,
1909+
// },
1910+
// "inComment2": {
1911+
// list: nil,
1912+
// },
1913+
// "inComment3": {
1914+
// list: nil,
1915+
// },
1916+
// "inComment4": {
1917+
// list: nil,
1918+
// },
1919+
// "inComment5": {
1920+
// list: nil,
1921+
// },
1922+
// "inTypeAlias": {
1923+
// list: nil,
1924+
// },
1925+
// "inRegExp1": {
1926+
// list: nil,
1927+
// },
19181928
},
19191929
},
19201930
}

internal/ls/utilities.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,7 +58,7 @@ func tryGetImportFromModuleSpecifier(node *ast.StringLiteralLike) *ast.Node {
5858
return nil
5959
}
6060

61-
// !!!
61+
// !!! formatting function
6262
func isInComment(file *ast.SourceFile, position int, tokenAtPosition *ast.Node) *ast.CommentRange {
6363
return nil
6464
}

0 commit comments

Comments
 (0)