@@ -525,7 +525,7 @@ test('look for VS2019 by version number', function (t) {
525
525
finder . findVisualStudio ( )
526
526
} )
527
527
528
- test ( 'look for VS2017 by installation path' , function ( t ) {
528
+ test ( 'look for VS2019 by installation path' , function ( t ) {
529
529
t . plan ( 2 )
530
530
531
531
const finder = new TestVisualStudioFinder ( semverV1 ,
@@ -540,6 +540,21 @@ test('look for VS2017 by installation path', function (t) {
540
540
finder . findVisualStudio ( )
541
541
} )
542
542
543
+ test ( 'msvs_version match should be case insensitive' , function ( t ) {
544
+ t . plan ( 2 )
545
+
546
+ const finder = new TestVisualStudioFinder ( semverV1 ,
547
+ 'c:\\program files (x86)\\microsoft visual studio\\2019\\BUILDTOOLS' ,
548
+ ( err , info ) => {
549
+ t . strictEqual ( err , null )
550
+ t . deepEqual ( info . path ,
551
+ 'C:\\Program Files (x86)\\Microsoft Visual Studio\\2019\\BuildTools' )
552
+ } )
553
+
554
+ allVsVersions ( t , finder )
555
+ finder . findVisualStudio ( )
556
+ } )
557
+
543
558
test ( 'latest version should be found by default' , function ( t ) {
544
559
t . plan ( 2 )
545
560
@@ -568,6 +583,22 @@ test('run on a usable VS Command Prompt', function (t) {
568
583
finder . findVisualStudio ( )
569
584
} )
570
585
586
+ test ( 'VCINSTALLDIR match should be case insensitive' , function ( t ) {
587
+ t . plan ( 2 )
588
+
589
+ process . env . VCINSTALLDIR =
590
+ 'c:\\program files (x86)\\microsoft visual studio\\2019\\BUILDTOOLS\\VC'
591
+
592
+ const finder = new TestVisualStudioFinder ( semverV1 , null , ( err , info ) => {
593
+ t . strictEqual ( err , null )
594
+ t . deepEqual ( info . path ,
595
+ 'C:\\Program Files (x86)\\Microsoft Visual Studio\\2019\\BuildTools' )
596
+ } )
597
+
598
+ allVsVersions ( t , finder )
599
+ finder . findVisualStudio ( )
600
+ } )
601
+
571
602
test ( 'run on a unusable VS Command Prompt' , function ( t ) {
572
603
t . plan ( 2 )
573
604
0 commit comments