mirror of
https://github.com/aphrody-labs/PowerShell.git
synced 2026-10-17 12:45:47 +00:00
Unify pester test syntax for the arguments of -BeOfType (#11558)
This commit is contained in:
1 parent
a7a2b12336
commit
920b671fb4
68 files changed
+216
-216
No files matched your search
@@ -91,8 +91,8 @@ try {
|
||||
# in a runspace that has not been opened.
|
||||
$err = { $ps.AddScript('1+1').InvokeAsync() } | Should -Throw -ErrorId "InvalidRunspaceStateException" -PassThru
|
||||
|
||||
$err.Exception | Should -BeOfType "System.Management.Automation.MethodInvocationException"
|
||||
$err.Exception.InnerException | Should -BeOfType "System.Management.Automation.Runspaces.InvalidRunspaceStateException"
|
||||
$err.Exception | Should -BeOfType System.Management.Automation.MethodInvocationException
|
||||
$err.Exception.InnerException | Should -BeOfType System.Management.Automation.Runspaces.InvalidRunspaceStateException
|
||||
$err.Exception.InnerException.CurrentState | Should -Be 'BeforeOpen'
|
||||
$err.Exception.InnerException.ExpectedState | Should -Be 'Opened'
|
||||
} finally {
|
||||
|
||||
Reference in new issue
Block a user