From 66708241f7f2d1683f515644bd3a135198bd63e5 Mon Sep 17 00:00:00 2001 From: James Truher Date: Tue, 24 Jan 2023 13:03:51 -0800 Subject: [PATCH] Change test so output does not include newline. --- test/powershell/engine/Api/PSCommand.Tests.ps1 | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/test/powershell/engine/Api/PSCommand.Tests.ps1 b/test/powershell/engine/Api/PSCommand.Tests.ps1 index 373951cd29e..0b0be2280f8 100644 --- a/test/powershell/engine/Api/PSCommand.Tests.ps1 +++ b/test/powershell/engine/Api/PSCommand.Tests.ps1 @@ -54,14 +54,13 @@ Describe "PSCommand API tests" -Tag "CI" { # We manually create a CmdletInfo here (with an unresolable command) to verify that CmdletInfo's are cloned. $cmdlet = [System.Management.Automation.CmdletInfo]::new('un-resolvable', [Microsoft.PowerShell.Commands.OutStringCommand]) - $null = $otherShell.AddCommand($cmdlet).AddParameter("InputObject", 'test') + $null = $otherShell.AddCommand($cmdlet).AddParameter("InputObject", 'test').AddParameter("Stream") # Setter for "Commands" calls PSCommand.Clone() $shell.Commands = $otherShell.Commands $result = $shell.Invoke() - $result | Should -Be "test -" + $result | Should -Be "test" } finally { $otherShell.Dispose()