@@ -285,14 +285,13 @@ func TestAta(t *testing.T) {
285
285
})
286
286
287
287
t .Run ("discover from node_modules" , func (t * testing.T ) {
288
- t .Skip ("Skip for now - to add back when we skip external library files to lookup typings for" )
289
288
t .Parallel ()
290
289
files := map [string ]any {
291
290
"/user/username/projects/project/app.js" : "" ,
292
291
"/user/username/projects/project/package.json" : `{
293
292
"dependencies": {
294
- "jquery": "1.0.0",
295
- },
293
+ "jquery": "1.0.0"
294
+ }
296
295
}` ,
297
296
"/user/username/projects/project/jsconfig.json" : `{}` ,
298
297
"/user/username/projects/project/node_modules/commander/index.js" : "" ,
@@ -312,7 +311,6 @@ func TestAta(t *testing.T) {
312
311
313
312
service .OpenFile ("/user/username/projects/project/app.js" , files ["/user/username/projects/project/app.js" ].(string ), core .ScriptKindJS , "" )
314
313
_ , p := service .EnsureDefaultProjectForFile ("/user/username/projects/project/app.js" )
315
- // Order is determinate since second install will run only after completing first one
316
314
status := <- host .ServiceOptions .InstallStatus
317
315
assert .Equal (t , status , project.TypingsInstallerStatus {
318
316
RequestId : 1 ,
@@ -323,14 +321,13 @@ func TestAta(t *testing.T) {
323
321
324
322
// Explicit types prevent automatic inclusion from package.json listing
325
323
t .Run ("discover from node_modules empty types" , func (t * testing.T ) {
326
- t .Skip ("Skip for now - to add back when we skip external library files to lookup typings for" )
327
324
t .Parallel ()
328
325
files := map [string ]any {
329
326
"/user/username/projects/project/app.js" : "" ,
330
327
"/user/username/projects/project/package.json" : `{
331
328
"dependencies": {
332
- "jquery": "1.0.0",
333
- },
329
+ "jquery": "1.0.0"
330
+ }
334
331
}` ,
335
332
"/user/username/projects/project/jsconfig.json" : `{
336
333
"compilerOptions": {
@@ -354,25 +351,23 @@ func TestAta(t *testing.T) {
354
351
355
352
service .OpenFile ("/user/username/projects/project/app.js" , files ["/user/username/projects/project/app.js" ].(string ), core .ScriptKindJS , "" )
356
353
_ , p := service .EnsureDefaultProjectForFile ("/user/username/projects/project/app.js" )
357
- // Order is determinate since second install will run only after completing first one
358
354
status := <- host .ServiceOptions .InstallStatus
359
355
assert .Equal (t , status , project.TypingsInstallerStatus {
360
356
RequestId : 1 ,
361
357
Project : p ,
362
- Status : "Success " ,
358
+ Status : "Skipped 0 typings " ,
363
359
})
364
360
})
365
361
366
362
// A type reference directive will not resolve to the global typings cache
367
363
t .Run ("discover from node_modules explicit types" , func (t * testing.T ) {
368
- t .Skip ("Skip for now - to add back when we skip external library files to lookup typings for" )
369
364
t .Parallel ()
370
365
files := map [string ]any {
371
366
"/user/username/projects/project/app.js" : "" ,
372
367
"/user/username/projects/project/package.json" : `{
373
368
"dependencies": {
374
- "jquery": "1.0.0",
375
- },
369
+ "jquery": "1.0.0"
370
+ }
376
371
}` ,
377
372
"/user/username/projects/project/jsconfig.json" : `{
378
373
"compilerOptions": {
@@ -396,25 +391,23 @@ func TestAta(t *testing.T) {
396
391
397
392
service .OpenFile ("/user/username/projects/project/app.js" , files ["/user/username/projects/project/app.js" ].(string ), core .ScriptKindJS , "" )
398
393
_ , p := service .EnsureDefaultProjectForFile ("/user/username/projects/project/app.js" )
399
- // Order is determinate since second install will run only after completing first one
400
394
status := <- host .ServiceOptions .InstallStatus
401
395
assert .Equal (t , status , project.TypingsInstallerStatus {
402
396
RequestId : 1 ,
403
397
Project : p ,
404
- Status : "Success " ,
398
+ Status : "Skipped 0 typings " ,
405
399
})
406
400
})
407
401
408
402
// However, explicit types will not prevent unresolved imports from pulling in typings
409
403
t .Run ("discover from node_modules empty types has import" , func (t * testing.T ) {
410
- t .Skip ("Skip for now - to add back when we skip external library files to lookup typings for" )
411
404
t .Parallel ()
412
405
files := map [string ]any {
413
406
"/user/username/projects/project/app.js" : `import "jquery";` ,
414
407
"/user/username/projects/project/package.json" : `{
415
408
"dependencies": {
416
- "jquery": "1.0.0",
417
- },
409
+ "jquery": "1.0.0"
410
+ }
418
411
}` ,
419
412
"/user/username/projects/project/jsconfig.json" : `{
420
413
"compilerOptions": {
@@ -438,7 +431,6 @@ func TestAta(t *testing.T) {
438
431
439
432
service .OpenFile ("/user/username/projects/project/app.js" , files ["/user/username/projects/project/app.js" ].(string ), core .ScriptKindJS , "" )
440
433
_ , p := service .EnsureDefaultProjectForFile ("/user/username/projects/project/app.js" )
441
- // Order is determinate since second install will run only after completing first one
442
434
status := <- host .ServiceOptions .InstallStatus
443
435
assert .Equal (t , status , project.TypingsInstallerStatus {
444
436
RequestId : 1 ,
0 commit comments