We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent fab07eb commit ead6e9dCopy full SHA for ead6e9d
test/Microsoft.PowerShell.ThreadJob.Tests.ps1
@@ -440,8 +440,6 @@ Describe 'Job2 class API tests' -Tags 'CI' {
440
It 'Verifies terminating job error' {
441
442
$job = Start-ThreadJob -ScriptBlock { throw "My Job Error!" } | Wait-Job
443
- $results = $job | Receive-Job 2>&1
444
- $results | Should -Not -BeNullOrEmpty
445
- $results[0].Exception.Message | Should -Be "My Job Error!"
+ $job.JobStateInfo.Reason.Message | Should -Be "My Job Error!"
446
}
447
0 commit comments