Correct case of $NestedPromptLevel special variable

This commit is contained in:
xtqqczze
2020-01-13 19:13:53 +00:00
parent fbe459d480
commit f86f30cf64
+1 -1
View File
@@ -571,7 +571,7 @@ foo
}
It "Redirected input w/ nested prompt" -Pending:($IsWindows) {
$si = NewProcessStartInfo "-noprofile -noexit -c ""`$function:prompt = { 'PS' + ('>'*(`$nestedPromptLevel+1)) + ' ' }""" -RedirectStdIn
$si = NewProcessStartInfo "-noprofile -noexit -c ""`$function:prompt = { 'PS' + ('>'*(`$NestedPromptLevel+1)) + ' ' }""" -RedirectStdIn
$process = RunPowerShell $si
$process.StandardInput.Write("`$host.EnterNestedPrompt()`n")
$process.StandardOutput.ReadLine() | Should -Be "PS> `$host.EnterNestedPrompt()"