File tree Expand file tree Collapse file tree 2 files changed +17
-0
lines changed Expand file tree Collapse file tree 2 files changed +17
-0
lines changed Original file line number Diff line number Diff line change @@ -151,6 +151,9 @@ private void DynamicHelpImpl(bool isFullHelp)
151151 string commandName = null ;
152152 string parameterName = null ;
153153
154+ // Simply return if nothing is rendered yet.
155+ if ( _singleton . _tokens == null ) { return ; }
156+
154157 foreach ( var token in _singleton . _tokens )
155158 {
156159 var extent = token . Extent ;
Original file line number Diff line number Diff line change @@ -97,6 +97,13 @@ private static PSObject GetParameterHelpObject(string description)
9797 return paramHelp ;
9898 }
9999
100+ [ SkippableFact ]
101+ public void DynHelp_GetFullHelp_OnEmptyLine ( )
102+ {
103+ TestSetup ( KeyMode . Cmd ) ;
104+ Test ( "" , Keys ( _ . F1 , _ . Enter ) ) ;
105+ }
106+
100107 [ SkippableFact ]
101108 public void DynHelp_GetFullHelp ( )
102109 {
@@ -108,6 +115,13 @@ public void DynHelp_GetFullHelp()
108115 ) ) ;
109116 }
110117
118+ [ SkippableFact ]
119+ public void DynHelp_GetParameterHelp_OnEmptyLine ( )
120+ {
121+ TestSetup ( KeyMode . Cmd ) ;
122+ Test ( "" , Keys ( _ . Alt_h , _ . Enter ) ) ;
123+ }
124+
111125 [ SkippableFact ]
112126 public void DynHelp_GetParameterHelp_And_Clear ( )
113127 {
You can’t perform that action at this time.
0 commit comments