| FazBrowse GitHub Viewer | Trending | | Home |
| Tools: [Download Repo ZIP] [Original HTTPS Page] |
…rs (#2385) Invoke the correct overload of SessionState.Path.GetResolvedPSPathFromPSPath, passing the cmdlet context object.
|
Ilya (@iSazonov) Can you take a look at the Appveyor failure? I'm looking at the details and they seem to show two failure points, neither of which have anything to do with this PR. |
Sorry, something went wrong.
|
jeffbi I see the same in other PRs. Nightly builds is affected too. |
Sorry, something went wrong.
There was a problem hiding this comment.
Original Issue say that the cmdlet works well but writes unexpected error message - I don't see the check in tests.
Sorry, something went wrong.
|
Ilya (@iSazonov) Well, what it actually said what that the cmdlet successfully performed the action that was intended, then wrote an error. That's not quite the same as it worked well. I've updated the tests to check that the Move-Item was successful, and also to verify that files meant to be unaffected were unaffected. |
Sorry, something went wrong.
|
LGTM. |
Sorry, something went wrong.
| $booContent = "boo content" | ||
| } | ||
| BeforeEach { | ||
| New-Item -ItemType Directory -Path $filterPath |
There was a problem hiding this comment.
Should be
New-Item -ItemType Directory -Path $filterPath | Out-Nullto avoid on console output of created item
Sorry, something went wrong.
There was a problem hiding this comment.
Fixed.
Sorry, something went wrong.
| It "Can move to different directory, filtered with -Include" { | ||
| Move-Item -Path $filePath -Destination $moveToPath -Include "bar*" | ||
| $? | Should Be $true | ||
| Test-Path -Path $barPath | Should Be $false |
There was a problem hiding this comment.
Use Powershell $barPath | Should Not Exist"
Sorry, something went wrong.
There was a problem hiding this comment.
Fixed
Sorry, something went wrong.
| } | ||
| It "Can move to different directory, filtered with -Include" { | ||
| Move-Item -Path $filePath -Destination $moveToPath -Include "bar*" | ||
| $? | Should Be $true |
There was a problem hiding this comment.
Difficult to debug from logs. Instead use
Move-Item -Path $filePath -Destination $moveToPath -Include "bar*" -ErrorVariable e -ErrorAction SilentlyContinue
$e | Should BeNullOrEmpty
Sorry, something went wrong.
There was a problem hiding this comment.
Fixed
Sorry, something went wrong.
| It "Can move to different directory, filtered with -Include" { | ||
| Move-Item -Path $filePath -Destination $moveToPath -Include "bar*" -ErrorVariable e -ErrorAction SilentlyContinue | ||
| $e | Should BeNullOrEmpty | ||
| #Test-Path -Path $barPath | Should Be $false |
There was a problem hiding this comment.
Please remove the comment.
Sorry, something went wrong.
There was a problem hiding this comment.
Thanks for catching that. Fixed.
Sorry, something went wrong.
|
jeffbi Thanks for the fix! LGTM. (After removing one unneeded comment) |
Sorry, something went wrong.
|
Ilya (@iSazonov), Aditya Patwardhan (@adityapatwardhan) Thanks for the review. |
Sorry, something went wrong.
|
jeffbi Can you update or remove the company in your profile? If it is accurate, please email me internally about additional steps you need to take. Aditya Patwardhan (@adityapatwardhan) Please make your Microsoft Organization membership public. |
Sorry, something went wrong.
…rs (PowerShell#3878) * Make Move-Item work with its -Include, -Exclude, and -Filter parameters (PowerShell#2385) Invoke the correct overload of SessionState.Path.GetResolvedPSPathFromPSPath, passing the cmdlet context object. * Update tests per code review. * Changes per code review. * Remove stray comment
| Back | FazBrowse Home | New Git URL |
Fixed #2385
Invoke the correct overload of SessionState.Path.GetResolvedPSPathFromPSPath, passing the cmdlet context object.