@@ -29,8 +29,8 @@ describe('Language Service', () => {
2929 const doc = TextDocument . create ( 'file://test' , 'plaintext' , 1 , text ) ;
3030 const completions = ls . getCompletions ( {
3131 textDocument : doc ,
32- variables : { foo : 123 , bar : 'test' } ,
33- position : { line : 0 , character : 3 }
32+ variables : { foo : 123 , bar : 'test' } ,
33+ position : { line : 0 , character : 3 }
3434 } ) ;
3535 const labels = completions . map ( c => c . label ) ;
3636 expect ( labels ) . toContain ( 'foo' ) ;
@@ -41,8 +41,8 @@ describe('Language Service', () => {
4141 const doc = TextDocument . create ( 'file://test' , 'plaintext' , 1 , text ) ;
4242 const completions = ls . getCompletions ( {
4343 textDocument : doc ,
44- variables : { max : 10 , min : 5 , foo : 1 } ,
45- position : { line : 0 , character : 2 }
44+ variables : { max : 10 , min : 5 , foo : 1 } ,
45+ position : { line : 0 , character : 2 }
4646 } ) ;
4747 const labels = completions . map ( c => c . label ) ;
4848 expect ( labels ) . toContain ( 'max' ) ;
@@ -55,8 +55,8 @@ describe('Language Service', () => {
5555 const doc = TextDocument . create ( 'file://test' , 'plaintext' , 1 , text ) ;
5656 const completions = ls . getCompletions ( {
5757 textDocument : doc ,
58- variables : { max : 10 , foo : 1 } ,
59- position : { line : 0 , character : 2 }
58+ variables : { max : 10 , foo : 1 } ,
59+ position : { line : 0 , character : 2 }
6060 } ) ;
6161 const labels = completions . map ( c => c . label ) ;
6262 expect ( labels ) . toContain ( 'max' ) ;
@@ -67,8 +67,8 @@ describe('Language Service', () => {
6767 const doc = TextDocument . create ( 'file://test' , 'plaintext' , 1 , text ) ;
6868 const completions = ls . getCompletions ( {
6969 textDocument : doc ,
70- variables : { foo : 1 , bar : 2 } ,
71- position : { line : 0 , character : 0 }
70+ variables : { foo : 1 , bar : 2 } ,
71+ position : { line : 0 , character : 0 }
7272 } ) ;
7373 const labels = completions . map ( c => c . label ) ;
7474 expect ( labels ) . toContain ( 'foo' ) ;
@@ -82,7 +82,7 @@ describe('Language Service', () => {
8282 const completions = ls . getCompletions ( {
8383 textDocument : doc ,
8484 variables : undefined ,
85- position : { line : 0 , character : 3 }
85+ position : { line : 0 , character : 3 }
8686 } ) ;
8787 const labels = completions . map ( c => c . label ) ;
8888 expect ( labels ) . not . toContain ( 'foo' ) ;
@@ -93,7 +93,7 @@ describe('Language Service', () => {
9393 const doc = TextDocument . create ( 'file://test' , 'plaintext' , 1 , text ) ;
9494 const completions = ls . getCompletions ( {
9595 textDocument : doc ,
96- position : { line : 0 , character : 3 }
96+ position : { line : 0 , character : 3 }
9797 } ) ;
9898 const labels = completions . map ( c => c . label ) ;
9999 expect ( labels ) . toContain ( 'sin' ) ;
@@ -104,7 +104,7 @@ describe('Language Service', () => {
104104 const doc = TextDocument . create ( 'file://test' , 'plaintext' , 1 , text ) ;
105105 const completions = ls . getCompletions ( {
106106 textDocument : doc ,
107- position : { line : 0 , character : 2 }
107+ position : { line : 0 , character : 2 }
108108 } ) ;
109109 const labels = completions . map ( c => c . label ) ;
110110 expect ( labels ) . toContain ( 'PI' ) ;
@@ -115,7 +115,7 @@ describe('Language Service', () => {
115115 const doc = TextDocument . create ( 'file://test' , 'plaintext' , 1 , text ) ;
116116 const completions = ls . getCompletions ( {
117117 textDocument : doc ,
118- position : { line : 0 , character : 2 }
118+ position : { line : 0 , character : 2 }
119119 } ) ;
120120 const labels = completions . map ( c => c . label ) ;
121121 expect ( labels ) . toContain ( 'case' ) ;
@@ -126,8 +126,8 @@ describe('Language Service', () => {
126126 const doc = TextDocument . create ( 'file://test' , 'plaintext' , 1 , text ) ;
127127 const completions = ls . getCompletions ( {
128128 textDocument : doc ,
129- variables : { foo : { bar : 1 } } ,
130- position : { line : 0 , character : 4 }
129+ variables : { foo : { bar : 1 } } ,
130+ position : { line : 0 , character : 4 }
131131 } ) ;
132132 expect ( completions . length ) . toBeGreaterThan ( 0 ) ;
133133 const item = completions . find ( c => c . label === 'foo.bar' ) ;
@@ -140,8 +140,8 @@ describe('Language Service', () => {
140140 const doc = TextDocument . create ( 'file://test' , 'plaintext' , 1 , text ) ;
141141 const completions = ls . getCompletions ( {
142142 textDocument : doc ,
143- variables : { sine : 1 } ,
144- position : { line : 0 , character : 2 }
143+ variables : { sine : 1 } ,
144+ position : { line : 0 , character : 2 }
145145 } ) ;
146146
147147 const sinFunc = completions . find ( c => c . label === 'sin' ) ;
@@ -161,8 +161,8 @@ describe('Language Service', () => {
161161 const doc = TextDocument . create ( 'file://test' , 'plaintext' , 1 , text ) ;
162162 const completions = ls . getCompletions ( {
163163 textDocument : doc ,
164- variables : { myVar : 42 } ,
165- position : { line : 0 , character : 2 }
164+ variables : { myVar : 42 } ,
165+ position : { line : 0 , character : 2 }
166166 } ) ;
167167
168168 const varCompletion = completions . find ( c => c . label === 'myVar' ) ;
@@ -176,7 +176,7 @@ describe('Language Service', () => {
176176 const doc = TextDocument . create ( 'file://test' , 'plaintext' , 1 , text ) ;
177177 const completions = ls . getCompletions ( {
178178 textDocument : doc ,
179- position : { line : 0 , character : 1 }
179+ position : { line : 0 , character : 1 }
180180 } ) ;
181181
182182 const eConst = completions . find ( c => c . label === 'E' ) ;
@@ -196,7 +196,7 @@ describe('Language Service', () => {
196196 boolVar : true ,
197197 nullVar : null
198198 } ,
199- position : { line : 0 , character : 0 }
199+ position : { line : 0 , character : 0 }
200200 } ) ;
201201
202202 expect ( completions . find ( c => c . label === 'numVar' ) ?. detail ) . toBe ( 'number' ) ;
@@ -215,7 +215,7 @@ describe('Language Service', () => {
215215 variables : {
216216 arr : [ 10 , 20 , 30 ]
217217 } ,
218- position : { line : 0 , character : 3 }
218+ position : { line : 0 , character : 3 }
219219 } ) ;
220220
221221 const arrayItem = completions . find ( c => c . label === 'arr[]' ) ;
@@ -234,10 +234,10 @@ describe('Language Service', () => {
234234 textDocument : doc ,
235235 variables : {
236236 arr : [
237- { foo : 1 , bar : 2 }
237+ { foo : 1 , bar : 2 }
238238 ]
239239 } ,
240- position : { line : 0 , character : text . length }
240+ position : { line : 0 , character : text . length }
241241 } ) ;
242242
243243 expect ( completions . length ) . toBeGreaterThan ( 0 ) ;
@@ -256,11 +256,11 @@ describe('Language Service', () => {
256256 variables : {
257257 matrix : [
258258 [
259- { value : 42 }
259+ { value : 42 }
260260 ]
261261 ]
262262 } ,
263- position : { line : 0 , character : text . length }
263+ position : { line : 0 , character : text . length }
264264 } ) ;
265265
266266 const valueItem = completions . find ( c => c . label === 'matrix[0][1].value' ) ;
@@ -277,7 +277,7 @@ describe('Language Service', () => {
277277 variables : {
278278 arr : [ 1 , 2 , 3 ]
279279 } ,
280- position : { line : 0 , character : 3 }
280+ position : { line : 0 , character : 3 }
281281 } ) ;
282282
283283 const arrayItem = completions . find ( c => c . label === 'arr[]' ) ;
@@ -295,8 +295,8 @@ describe('Language Service', () => {
295295 const doc = TextDocument . create ( 'file://test' , 'plaintext' , 1 , text ) ;
296296 const hover = ls . getHover ( {
297297 textDocument : doc ,
298- position : { line : 0 , character : 1 } ,
299- variables : { foo : 42 }
298+ position : { line : 0 , character : 1 } ,
299+ variables : { foo : 42 }
300300 } ) ;
301301
302302 const contents = getContentsValue ( hover . contents ) ;
@@ -309,7 +309,7 @@ describe('Language Service', () => {
309309 const doc = TextDocument . create ( 'file://test' , 'plaintext' , 1 , text ) ;
310310 const hover = ls . getHover ( {
311311 textDocument : doc ,
312- position : { line : 0 , character : 1 } ,
312+ position : { line : 0 , character : 1 } ,
313313 variables : { }
314314 } ) ;
315315
@@ -322,7 +322,7 @@ describe('Language Service', () => {
322322 const doc = TextDocument . create ( 'file://test' , 'plaintext' , 1 , text ) ;
323323 const hover = ls . getHover ( {
324324 textDocument : doc ,
325- position : { line : 0 , character : 1 } ,
325+ position : { line : 0 , character : 1 } ,
326326 variables : { }
327327 } ) ;
328328
@@ -336,7 +336,7 @@ describe('Language Service', () => {
336336 const doc = TextDocument . create ( 'file://test' , 'plaintext' , 1 , text ) ;
337337 const hover = ls . getHover ( {
338338 textDocument : doc ,
339- position : { line : 0 , character : 1 } ,
339+ position : { line : 0 , character : 1 } ,
340340 variables : { }
341341 } ) ;
342342
@@ -349,7 +349,7 @@ describe('Language Service', () => {
349349 const doc = TextDocument . create ( 'file://test' , 'plaintext' , 1 , text ) ;
350350 const hover = ls . getHover ( {
351351 textDocument : doc ,
352- position : { line : 0 , character : 2 } ,
352+ position : { line : 0 , character : 2 } ,
353353 variables : { }
354354 } ) ;
355355
@@ -363,7 +363,7 @@ describe('Language Service', () => {
363363 const doc = TextDocument . create ( 'file://test' , 'plaintext' , 1 , text ) ;
364364 const hover = ls . getHover ( {
365365 textDocument : doc ,
366- position : { line : 0 , character : 1 } ,
366+ position : { line : 0 , character : 1 } ,
367367 variables : { }
368368 } ) ;
369369
@@ -376,7 +376,7 @@ describe('Language Service', () => {
376376 const doc = TextDocument . create ( 'file://test' , 'plaintext' , 1 , text ) ;
377377 const hover = ls . getHover ( {
378378 textDocument : doc ,
379- position : { line : 0 , character : 2 } ,
379+ position : { line : 0 , character : 2 } ,
380380 variables : { }
381381 } ) ;
382382
@@ -389,7 +389,7 @@ describe('Language Service', () => {
389389 const doc = TextDocument . create ( 'file://test' , 'plaintext' , 1 , text ) ;
390390 const hover = ls . getHover ( {
391391 textDocument : doc ,
392- position : { line : 0 , character : 0 } ,
392+ position : { line : 0 , character : 0 } ,
393393 variables : { }
394394 } ) ;
395395
@@ -401,8 +401,8 @@ describe('Language Service', () => {
401401 const doc = TextDocument . create ( 'file://test' , 'plaintext' , 1 , text ) ;
402402 const hover = ls . getHover ( {
403403 textDocument : doc ,
404- position : { line : 0 , character : 1 } ,
405- variables : { myFunc : 'my-variable' }
404+ position : { line : 0 , character : 1 } ,
405+ variables : { myFunc : 'my-variable' }
406406 } ) ;
407407
408408 const contents = getContentsValue ( hover . contents ) ;
@@ -416,7 +416,7 @@ describe('Language Service', () => {
416416 const doc = TextDocument . create ( 'file://test' , 'plaintext' , 1 , text ) ;
417417 const hover = ls . getHover ( {
418418 textDocument : doc ,
419- position : { line : 0 , character : 1 }
419+ position : { line : 0 , character : 1 }
420420 } ) ;
421421
422422 const contents = hover . contents as any ;
@@ -434,8 +434,8 @@ describe('Language Service', () => {
434434 const doc = TextDocument . create ( 'file://test' , 'plaintext' , 1 , text ) ;
435435 const hover = ls . getHover ( {
436436 textDocument : doc ,
437- position : { line : 0 , character : 1 } ,
438- variables : { foo : 42 }
437+ position : { line : 0 , character : 1 } ,
438+ variables : { foo : 42 }
439439 } ) ;
440440
441441 const contents = hover . contents as any ;
@@ -558,13 +558,13 @@ describe('Language Service', () => {
558558
559559 const completions = ls . getCompletions ( {
560560 textDocument : doc ,
561- position : { line : 0 , character : 0 }
561+ position : { line : 0 , character : 0 }
562562 } ) ;
563563 expect ( Array . isArray ( completions ) ) . toBe ( true ) ;
564564
565565 const hover = ls . getHover ( {
566566 textDocument : doc ,
567- position : { line : 0 , character : 0 }
567+ position : { line : 0 , character : 0 }
568568 } ) ;
569569 expect ( hover ) . toBeDefined ( ) ;
570570
@@ -602,7 +602,7 @@ describe('Language Service', () => {
602602
603603 const completions = ls . getCompletions ( {
604604 textDocument : doc ,
605- position : { line : 0 , character : text . length }
605+ position : { line : 0 , character : text . length }
606606 } ) ;
607607 expect ( Array . isArray ( completions ) ) . toBe ( true ) ;
608608 } ) ;
@@ -613,7 +613,7 @@ describe('Language Service', () => {
613613
614614 const completions = ls . getCompletions ( {
615615 textDocument : doc ,
616- position : { line : 0 , character : 0 }
616+ position : { line : 0 , character : 0 }
617617 } ) ;
618618 expect ( Array . isArray ( completions ) ) . toBe ( true ) ;
619619 } ) ;
@@ -630,7 +630,7 @@ describe('Language Service', () => {
630630
631631 it ( 'should create service with custom options' , ( ) => {
632632 const service = createLanguageService ( {
633- operators : { '+' : true , '-' : false }
633+ operators : { '+' : true , '-' : false }
634634 } ) ;
635635 expect ( service ) . toBeDefined ( ) ;
636636 } ) ;
0 commit comments