File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1212 `Should -Exist` calls Test-Path. Test-Path expects a file,
1313 returns $false because the file was removed, and fails the test.
1414 #>
15- [bool ] $succeeded = & $SafeCommands [' Test-Path' ] $ActualValue
15+ [bool ] $succeeded = & $SafeCommands [' Test-Path' ] - LiteralPath $ActualValue
1616
1717 if ($Negate ) {
1818 $succeeded = -not $succeeded
Original file line number Diff line number Diff line change @@ -11,9 +11,9 @@ InPesterModuleScope {
1111 " TestDrive:\nonexistant" | Should -Not - Exist
1212 }
1313
14- It ' works for path with escaped [ ] characters' {
14+ It ' works for path with literal [ ] characters' {
1515 New-Item - Path " TestDrive:\[test].txt" - ItemType File | Out-Null
16- " TestDrive:\`` [test`` ].txt" | Should - Exist
16+ " TestDrive:\[test].txt" | Should - Exist
1717 }
1818
1919 It ' returns correct result for function drive' {
You can’t perform that action at this time.
0 commit comments