Commit Graph

27 Commits

Author SHA1 Message Date
Raphaël Pinson 96a1622b03
github_user: add acceptance tests 2017-05-17 17:07:15 +02:00
Raphaël Pinson 5833ffe0d1
Use username instead of Id in log 2017-05-17 16:53:32 +02:00
Raphaël Pinson fc0d197be8
Add github_user data source 2017-05-17 15:04:25 +02:00
Radek Simko 4041db698c
provider/github: Randomize repository collaborator acc tests 2017-05-13 11:11:41 +02:00
Radek Simko 23bb27e5f5
provider/github: Randomize team repository acc tests 2017-05-13 11:11:39 +02:00
Radek Simko af47810e30
provider/github: Randomize issue label acc tests 2017-05-13 11:11:38 +02:00
Radek Simko b6edff80d8
provider/github: Randomize branch protection acc tests 2017-05-13 11:08:51 +02:00
Radek Simko 23c004b689 provider/github: Log HTTP requests and responses in DEBUG mode (#14363) 2017-05-11 13:06:05 +02:00
Andy Lindeman 46fd77bbed Clears branch protection from state only if error is an HTTP 404 (#13887) 2017-04-24 18:19:27 +01:00
Andy Lindeman 28d71e6624 provider/github: Implements github_branch_protection (#10476) 2017-04-20 21:11:49 +03:00
Seth Vargo 33dd504593
Add test 2017-03-31 11:45:21 -04:00
Seth Vargo c44487caee
Handle the case when issue labels already exist
This fixes GH-13163
2017-03-31 11:44:46 -04:00
Raphael Randschau 6991ceb2e2 provider/github: add repository_webhook resource (#12924)
* provider/github: add repository_webhook resource

`repository_webhook` can be used to manage webhooks for repositories.
It is currently limited to organization repositories only.

The changeset includes both documentation and tests.
The tests are green:

```
make testacc TEST=./builtin/providers/github
TESTARGS='-run=TestAccGithubRepositoryWebhook_basic'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/03/21 16:20:07 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/github -v
-run=TestAccGithubRepositoryWebhook_basic -timeout 120m
=== RUN   TestAccGithubRepositoryWebhook_basic
--- PASS: TestAccGithubRepositoryWebhook_basic (5.10s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/github    5.113s
```

* provider/github: add github_organization_webhook

the `github_organization_webhook` resource is similar to the
`github_repository_webhook` resource, but it manages webhooks for an
organization.

the tests are green:

```
make testacc TEST=./builtin/providers/github
TESTARGS='-run=TestAccGithubOrganizationWebhook'
==> Checking that code complies with gofmt requirements...
go generate $(go list ./... | grep -v /terraform/vendor/)
2017/03/21 17:23:33 Generated command/internal_plugin_list.go
TF_ACC=1 go test ./builtin/providers/github -v
-run=TestAccGithubOrganizationWebhook -timeout 120m
=== RUN   TestAccGithubOrganizationWebhook_basic
--- PASS: TestAccGithubOrganizationWebhook_basic (2.09s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/github    2.109s
```
2017-03-23 11:21:45 +02:00
Radek Simko eddc8cce37 provider/github: Improve test failure message (#12978) 2017-03-23 09:19:03 +00:00
Radek Simko e6e2535d2e provider/github: Randomize repo and team names in acc tests (#12802) 2017-03-17 10:47:43 +00:00
Andy Lindeman 85f759f296 Updates google/go-github to the latest revision (#12604)
* Updates to the latest go-github

* `github_repository_collaborator` uses invitations API
2017-03-12 16:05:18 +02:00
Andy Lindeman 5ddf83907c provider/github: supports importing resources (#10382)
```
=== RUN   TestProvider
--- PASS: TestProvider (0.00s)
=== RUN   TestProvider_impl
--- PASS: TestProvider_impl (0.00s)
=== RUN   TestAccGithubIssueLabel_basic
--- PASS: TestAccGithubIssueLabel_basic (0.91s)
=== RUN   TestAccGithubIssueLabel_importBasic
--- PASS: TestAccGithubIssueLabel_importBasic (0.41s)
=== RUN   TestAccGithubMembership_basic
--- PASS: TestAccGithubMembership_basic (0.84s)
=== RUN   TestAccGithubMembership_importBasic
--- PASS: TestAccGithubMembership_importBasic (0.53s)
=== RUN   TestAccGithubRepositoryCollaborator_basic
--- PASS: TestAccGithubRepositoryCollaborator_basic (0.64s)
=== RUN   TestAccGithubRepositoryCollaborator_importBasic
--- PASS: TestAccGithubRepositoryCollaborator_importBasic (0.74s)
=== RUN   TestAccGithubRepository_basic
--- PASS: TestAccGithubRepository_basic (1.54s)
=== RUN   TestAccGithubRepository_importBasic
--- PASS: TestAccGithubRepository_importBasic (0.77s)
=== RUN   TestAccGithubTeamMembership_basic
--- PASS: TestAccGithubTeamMembership_basic (1.59s)
=== RUN   TestAccGithubTeamMembership_importBasic
--- PASS: TestAccGithubTeamMembership_importBasic (0.95s)
=== RUN   TestAccGithubTeamRepository_basic
--- PASS: TestAccGithubTeamRepository_basic (1.45s)
=== RUN   TestAccGithubTeamRepository_importBasic
--- PASS: TestAccGithubTeamRepository_importBasic (0.75s)
=== RUN   TestAccCheckGetPermissions
--- PASS: TestAccCheckGetPermissions (0.00s)
=== RUN   TestAccGithubTeam_basic
--- PASS: TestAccGithubTeam_basic (0.79s)
=== RUN   TestAccGithubTeam_importBasic
--- PASS: TestAccGithubTeam_importBasic (0.54s)
=== RUN   TestAccGithubUtilRole_validation
--- PASS: TestAccGithubUtilRole_validation (0.00s)
=== RUN   TestAccGithubUtilTwoPartID
--- PASS: TestAccGithubUtilTwoPartID (0.00s)
PASS
ok      github.com/hashicorp/terraform/builtin/providers/github 12.455s
```
2016-11-28 17:30:24 +00:00
Paul Stack dc0cb70e95 provider/github: Creating a github repository before adding a label (#10213) 2016-11-18 13:38:46 +02:00
Ian L f584d53ba9 provider/github: add GitHub labels resource (#10142)
* provider/github: add GitHub labels resource

Provides a GitHub issue label resource.

This resource allows easy management of issue labels for an
organisation's repositories. A name, and a color can be set.
These attributes can be updated without creating a new resource.

* provider/github: add documentation for GitHub issue labels resource
2016-11-18 13:24:37 +02:00
Martin Atkins f4ecf72125 provider/github: github_repository resource
Allows creation of repositories within the organization configured on the
provider.
2016-10-13 08:04:17 -07:00
Radek Simko 1c12ead951 provider/github: Remove unsafe ptr dereferencing (#8512) 2016-08-28 17:15:03 +01:00
Michael Handler a1e92c6f77 +github_repository_collaborator (#6861) 2016-06-02 01:06:35 +01:00
Kevin DeJong 0cec1c19d7 Add support for the Base URL endpoint so the GitHub provider can support GitHub Enterprise (#6434) 2016-05-09 19:22:53 +01:00
James Nugent f2fef2556a Fix import formatting across code base 2016-04-18 17:28:46 -07:00
Jacob Severson 7721348b0b Adding privacy argument for GitHub teams for #6015 (#6116)
Added the ability to set the "privacy" of a github_team resource so all teams won't automatically set to private.

* Added the privacy argument to github_team

* Refactored parameter validation to be general for any argument

* Updated testing
2016-04-11 13:09:25 +01:00
Jacob Severson b1e7065878 Pulling out the hardcoded test user 2016-03-18 21:55:33 -05:00
Jacob Severson c1b373ad5f Add Github Organization provider.
Allows for managing organization membership, teams, team membership, and
team repositories.
2016-03-08 23:06:30 +01:00