You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Describe 'the host program' {
It 'supports user interaction' {
$Host.UI.RawUI.WindowTitle="magic"$title=$Host.UI.RawUI.WindowTitle$title| Should -Not-BeNullOrEmpty
}
}
It will successfully pass when executed with "Debug Test". However, when stared via "Run Test", it will fail on its first line (e.g. $Host.UI.RawUI.WindowTitle = "magic") with a message as:
Exception setting "WindowTitle": "A command that prompts the user failed because the host program or the command type does not support user interaction. Try a host program that supports user interaction, such as the PowerShell Console, and remove prompt-related commands from command types that do not support user interaction."
It would be also useful to have some defaults within properties of $Host.UI.RawUI.
The text was updated successfully, but these errors were encountered:
The test runs operate within their own dedicated process, so UI pester tests are unsupported there, however if you run the tests via debug then they run in the PS Extension which should be supported.
I do have a potential refactor coming to move everything into the PS Extension as a separate runspace which may make this functional
Have a simple test file like:
It will successfully pass when executed with "Debug Test". However, when stared via "Run Test", it will fail on its first line (e.g.
$Host.UI.RawUI.WindowTitle = "magic"
) with a message as:It would be also useful to have some defaults within properties of
$Host.UI.RawUI
.The text was updated successfully, but these errors were encountered: