mirror of
https://github.com/aphrody-labs/PowerShell.git
synced 2026-10-14 05:39:11 +00:00
Suppress error output from Set-Location tests (#20499)
This commit is contained in:
1 parent
42d791f863
commit
4fd4522b84
1 file changed
+2
-2
@@ -240,7 +240,7 @@ Describe "Set-Location" -Tags "CI" {
|
||||
It 'Should go to the parent folder on cd.. run' {
|
||||
Set-Location 'TestDrive:\'
|
||||
$ParentDir = (Get-Location).path
|
||||
New-Item -Path 'TestDrive:\' -Name 'Directory1' -ItemType Directory
|
||||
New-Item -Path 'TestDrive:\' -Name 'Directory1' -ItemType Directory -ErrorAction Ignore
|
||||
Set-Location 'TestDrive:\Directory1'
|
||||
cd..
|
||||
(Get-Location).Path | Should -BeExactly $ParentDir
|
||||
@@ -256,7 +256,7 @@ Describe "Set-Location" -Tags "CI" {
|
||||
}
|
||||
It 'Should go to root of current drive on cd\ run (Linux/Mac)' -Skip:($IsWindows){
|
||||
Set-Location 'TestDrive:\'
|
||||
New-Item -Path 'TestDrive:\Directory1' -Name 'Directory2' -ItemType Directory
|
||||
New-Item -Path 'TestDrive:\Directory1' -Name 'Directory2' -ItemType Directory -ErrorAction Ignore
|
||||
Set-Location 'TestDrive:\Directory1\Directory2'
|
||||
cd\
|
||||
(Get-Location).Path | Should -BeExactly "/"
|
||||
|
||||
Reference in new issue
Block a user