Skip to content

Latest commit

 

History

History

Incorrect-in-odd-location

Folders and files

NameName
Last commit message
Last commit date

parent directory

..
 
 
 
 
 
 
 
 

Test-Path oddities

Test-Path works incorrectly in some locations

Fixed in v6.2.0-preview.2

Test-Path and Test-Path -LiteralPath may work incorrectly with relative paths if the current location path is "odd".

The script Current.directory.with.odd.name.ps1 creates directories with odd names, sets the current location to them, and tests an existing item using Test-Path. Results are unexpected.

See also

  • Similar Get-Item issues
  • Microsoft Connect 389828

Test-Path gets true for a space

Fixed in v6.2.0-preview.3

This code

Test-Path ' '

always gets true.