-
Notifications
You must be signed in to change notification settings - Fork 188
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update GitHubRepositories Tests and Refactor Get-GitHubRepository Function #233
Update GitHubRepositories Tests and Refactor Get-GitHubRepository Function #233
Conversation
Thanks for this. Conflicts abound in the tests between this and the work going on for pipelining (which is nearly completed), so I'm going to hold off on this one until early next week if you don't mind.... |
Yep no problem Howard. I'll leave it in Draft state for now. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks so much for doing this. Increased code coverage in tests is always good, especially if it catches a dead block of code.
Looks like there are a few minor formatting issues and one bug introduced by this.
Otherwise, there may be some duplicative tests within here (especially around topics, collaborators and contributors) with the advent of the tests added for #242.
Can we trigger the CI for this PR? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Update looks great -- we just need to resolve the duplicative tests.
@HowardWolosky Can we trigger the CI for this PR? |
/azp run PowerShellForGitHub-CI |
Azure Pipelines successfully started running 1 pipeline(s). |
Now that #205 is in, you have some expected merge conflicts to deal with. |
/azp run PowerShellForGitHub-CI |
Azure Pipelines successfully started running 1 pipeline(s). |
Description
This PR updates the Pester tests for the
GitHubRepositories
module to increase the code coverage. This then exposed a code path in theGet-GithubRepository
that could never be taken, so the function was refactored to remove this path and simplify the function logic.A missing
ValidateSet
was also added to theAffiliation
parameter of theGet-GitHubRepository
function and incorrect Comment Based Help descriptions for theGet-GitHubRepositoryCollaborator
andMove-GitHubRepositoryOwnership
functions were fixed.Issues Fixed
None
References
N/A
Checklist
Changes to the manifest file follow the manifest guidance.Relevant usage examples have been added/updated in USAGE.md.If desired, ensure your name is added to our Contributors list