In case of failure rerun command in specified location#287
In case of failure rerun command in specified location#287devblackops merged 5 commits intopsake:masterfrom
Conversation
|
I was confused by your description at first, but looking at the commit, I think I understand what you mean. I think your example should read :
Is that correct? |
Yes, sorry for typo and confusion. |
|
I've raised a pull request against your branch which adds a Pester test for your change. |
|
Thanks @tiksn for the fix and thanks @UberDoodles for the tests! 👍 @tiksn Once you merge the test PR in, I'll merge this. |
devblackops
left a comment
There was a problem hiding this comment.
Thanks @tiksn. If you can merge the tests from @UberDoodles's PR, I'll merge this. 👍
Pester spec to verify that Exec executes script block in the specified working directory
|
Sorry @tiksn; looks like my test doesn't work on Ubuntu or Mac. I'll try and fix it later and raise another pull request. |
|
Sorry for the delay guys; been struggling for time. I think I've fixed this in my branch now, but it's just based on guessing what the issue is. I don't currently have a Linux / Mac to test it on. I'll get Ubuntu running as soon as I get chance and test it out. |
Altering Pester spec for Execs working directory to be cross-platform
|
Thanks @UberDoodles now all checks pass. |
In case of command failure retry running command on he location passed by caller
Description
Lets say caller wan't to Exec deletion of all files inside D:\ folder and retry it max 10 times.
We are running script in E:\ folder
Old/current code would have changed location to E:\ (correctly), try and fail on deleting all files and will pop location back to E:
Next 9 attempts will run inside E:
Now we will push and pop on each attempt
Related Issue
Mistake was in #200
Motivation and Context
Mentioned in description
How Has This Been Tested?
Because this is an easy fix I just tested in small sample build script
Screenshots (if appropriate):
Types of changes
Checklist: