@@ -369,6 +369,45 @@ func TestDefinition(t *testing.T) {
369
369
End : protocol.Position {Line : 7 , Character : 9 },
370
370
},
371
371
},
372
+ {
373
+ name : "goto with overrides: clobber string" ,
374
+ filename : "testdata/goto-overrides.jsonnet" ,
375
+ position : protocol.Position {Line : 38 , Character : 30 },
376
+ targetRange : protocol.Range {
377
+ Start : protocol.Position {Line : 24 , Character : 4 },
378
+ End : protocol.Position {Line : 24 , Character : 23 },
379
+ },
380
+ targetSelectionRange : protocol.Range {
381
+ Start : protocol.Position {Line : 24 , Character : 4 },
382
+ End : protocol.Position {Line : 24 , Character : 10 },
383
+ },
384
+ },
385
+ {
386
+ name : "goto with overrides: clobber nested string" ,
387
+ filename : "testdata/goto-overrides.jsonnet" ,
388
+ position : protocol.Position {Line : 39 , Character : 44 },
389
+ targetRange : protocol.Range {
390
+ Start : protocol.Position {Line : 26 , Character : 6 },
391
+ End : protocol.Position {Line : 26 , Character : 24 },
392
+ },
393
+ targetSelectionRange : protocol.Range {
394
+ Start : protocol.Position {Line : 26 , Character : 6 },
395
+ End : protocol.Position {Line : 26 , Character : 11 },
396
+ },
397
+ },
398
+ {
399
+ name : "goto with overrides: clobber map" ,
400
+ filename : "testdata/goto-overrides.jsonnet" ,
401
+ position : protocol.Position {Line : 40 , Character : 28 },
402
+ targetRange : protocol.Range {
403
+ Start : protocol.Position {Line : 28 , Character : 4 },
404
+ End : protocol.Position {Line : 28 , Character : 15 },
405
+ },
406
+ targetSelectionRange : protocol.Range {
407
+ Start : protocol.Position {Line : 28 , Character : 4 },
408
+ End : protocol.Position {Line : 28 , Character : 11 },
409
+ },
410
+ },
372
411
}
373
412
for _ , tc := range testCases {
374
413
t .Run (tc .name , func (t * testing.T ) {
0 commit comments