GeezerVisonThe World Wide Web, restored to 800 pixels of glory. | ||||||||||||||
| Home|About|Gaming cabinet|Archives|How it works|Starter sites | ||||||||||||||
GeezerVison is showing github.com — Remove empty directory when clone fails by YuPeiHenry · Pull Request #2241 · github/VisualStudio
This repository was archived by the owner on Jun 21, 2023. It is now read-only.
Conversation
|
|
|
||
| operatingSystem.Directory.Received().CreateDirectory(@"c:\dev\bar"); | ||
| operatingSystem.Directory.Received().DeleteDirectory(@"c:\dev\bar"); | ||
| await vsGitServices.Received().Clone("https://github.com/failing/url", @"c:\dev\bar", true); |
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Could you factor out "https://github.com/failing/url" and @"c:\dev\bar" into something like cloneUrl and clonePath?
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was an error while loading. Please reload this page.
|
@YuPeiHenry thank you for your contribution! |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
- Delete directory may throw errors, so log.Error should be called first.
- Assert.ThrowAsync statement have been shortened. - failing url and dev bar have been factored into clonePath and cloneUrl.
|
@jcansdale I have updated the PR to adopt your suggestions. |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
RepositoryCloneServiceTests and Substitutes were getting too coupled. This commit makes RepositoryCloneServiceTests self contained.
There was an error while loading. Please reload this page.
Successfully merging this pull request may close these issues.
Don't leave behind empty directory when a clone fails
There was an error while loading. Please reload this page.