Skip to content
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

API Coverage: Add Support for Deployment Environments #395

Merged
merged 11 commits into from
Apr 30, 2023
Prev Previous commit
Next Next commit
Apply suggestions from code review
Co-authored-by: Howard Wolosky <HowardWolosky@users.noreply.github.com>
  • Loading branch information
X-Guardian and HowardWolosky authored Feb 27, 2023
commit 919a10c0586d365b41c30806caca26665cb6f475
6 changes: 3 additions & 3 deletions GitHubDeployments.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -176,10 +176,10 @@ filter New-GitHubDeploymentEnvironment
$PSBoundParameters.ContainsKey('ReviewerUserId'))
{
$reviewers = @()
Foreach ($teamId in $ReviewerTeamId) {
foreach ($teamId in $ReviewerTeamId) {
$reviewers += @{ 'type' = 'Team'; 'id' = $teamId}
}
Foreach ($userId in $ReviewerUserId) {
foreach ($userId in $ReviewerUserId) {
$reviewers += @{ 'type' = 'User'; 'id' = $userId}
}
$hashBody['reviewers'] = $reviewers
Expand Down Expand Up @@ -216,7 +216,7 @@ filter Remove-GitHubDeploymentEnvironment
{
<#
.SYNOPSIS
Removes a deployment environment from a GitHub repository
Removes a deployment environment from a GitHub repository.

.DESCRIPTION
Removes a team from an organization on GitHub.
Expand Down
2 changes: 1 addition & 1 deletion Tests/GitHubDeployments.tests.ps1
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ BeforeAll {
$teamName = [Guid]::NewGuid().Guid
$description = 'Team Description'
$privacy = 'closed'
$MaintainerName = $script:ownerName
$maintainerName = $script:ownerName

$newGithubTeamParms = @{
OrganizationName = $script:organizationName
Expand Down
1 change: 0 additions & 1 deletion USAGE.md
Original file line number Diff line number Diff line change
Expand Up @@ -1266,7 +1266,6 @@ Set-GitHubDeploymentEnvironment -OwnerName microsoft -RepositoryName TestRepo -E
#### Removing an environment
```powershell
Remove-GitHubDeploymentEnvironment -OwnerName microsoft -RepositoryName TestRepo -Environment Test

```

----------
Expand Down