mirror of
https://github.com/PowerShell/PowerShell
synced 2026-06-08 12:12:50 +00:00
Add a test for chaining more than 2 native commands in pipeline (#4012)
This commit is contained in:
+12
-1
@@ -1,4 +1,4 @@
|
||||
Describe 'native commands lifecycle' -tags 'Feature' {
|
||||
Describe 'native commands with pipeline' -tags 'Feature' {
|
||||
|
||||
BeforeAll {
|
||||
$powershell = Join-Path -Path $PsHome -ChildPath "powershell"
|
||||
@@ -23,6 +23,17 @@ Describe 'native commands lifecycle' -tags 'Feature' {
|
||||
$ps.Stop()
|
||||
$rs.ResetRunspaceState()
|
||||
}
|
||||
|
||||
It "native | native | native should work fine" {
|
||||
|
||||
if ($IsWindows) {
|
||||
$result = @(ping.exe | findstr.exe count | findstr.exe ping)
|
||||
$result[0] | Should Match "Usage: ping"
|
||||
} else {
|
||||
$result = @(ps aux | grep powershell | grep -v grep)
|
||||
$result[0] | Should Match "powershell"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Describe "Native Command Processor" -tags "Feature" {
|
||||
|
||||
Reference in New Issue
Block a user