File tree 2 files changed +13
-1
lines changed
PowerShellEditorServices.Test/Debugging
PowerShellEditorServices.Test.Shared/Debugging
2 files changed +13
-1
lines changed Original file line number Diff line number Diff line change @@ -11,6 +11,8 @@ function Test-Variables {
11
11
$classVar = [MyClass ]::new();
12
12
$classVar.Name = " Test"
13
13
$classVar.Number = 42 ;
14
+ $trueVar = $true
15
+ $falseVar = $false
14
16
$enumVar = $ErrorActionPreference
15
17
$nullString = [NullString ]::Value
16
18
$psObjVar = New-Object - TypeName PSObject - Property @ {Name = ' John' ; Age = 75 }
Original file line number Diff line number Diff line change @@ -534,7 +534,7 @@ public async Task DebuggerGetsVariables()
534
534
{
535
535
await debugService . SetLineBreakpointsAsync (
536
536
variableScriptFile ,
537
- new [ ] { BreakpointDetails . Create ( variableScriptFile . FilePath , 14 ) } ) . ConfigureAwait ( true ) ;
537
+ new [ ] { BreakpointDetails . Create ( variableScriptFile . FilePath , 16 ) } ) . ConfigureAwait ( true ) ;
538
538
539
539
Task _ = ExecuteVariableScriptFile ( ) ;
540
540
AssertDebuggerStopped ( variableScriptFile . FilePath ) ;
@@ -567,6 +567,16 @@ await debugService.SetLineBreakpointsAsync(
567
567
568
568
var classChildren = debugService . GetVariables ( classVar . Id ) ;
569
569
Assert . Equal ( 2 , classChildren . Length ) ;
570
+
571
+ var trueVar = Array . Find ( variables , v => v . Name == "$trueVar" ) ;
572
+ Assert . NotNull ( trueVar ) ;
573
+ Assert . Equal ( "boolean" , trueVar . Type ) ;
574
+ Assert . Equal ( "$true" , trueVar . ValueString ) ;
575
+
576
+ var falseVar = Array . Find ( variables , v => v . Name == "$falseVar" ) ;
577
+ Assert . NotNull ( falseVar ) ;
578
+ Assert . Equal ( "boolean" , falseVar . Type ) ;
579
+ Assert . Equal ( "$false" , falseVar . ValueString ) ;
570
580
}
571
581
572
582
[ Trait ( "Category" , "DebugService" ) ]
You can’t perform that action at this time.
0 commit comments