Skip to content

Commit

Permalink
add tests to sema_token
Browse files Browse the repository at this point in the history
Signed-off-by: shruti2522 <[email protected]>
  • Loading branch information
shruti2522 committed May 31, 2024
1 parent 063b1ca commit 266f878
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
3 changes: 3 additions & 0 deletions kclvm/tools/src/LSP/src/semantic_token.rs
Original file line number Diff line number Diff line change
Expand Up @@ -155,6 +155,9 @@ mod tests {
(1, 4, 4, 2), // name
(2, 0, 1, 0), // n
(0, 3, 3, 4), // num
(1, 0, 4, 0), // func
(0, 14, 1, 0), // x
(1, 4, 1, 0), // x
];
let res = semantic_tokens_full(&file, &gs);
if let Some(tokens) = res {
Expand Down
5 changes: 4 additions & 1 deletion kclvm/tools/src/LSP/src/test_data/sema_token.k
Original file line number Diff line number Diff line change
Expand Up @@ -6,4 +6,7 @@ schema Persons:
p5: Persons = Persons {
name: "alice"
}
n: num = 1
n: num = 1
func = lambda x{
x
}

0 comments on commit 266f878

Please sign in to comment.