Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

chore: disable GitHub acceptance tests #1666

Merged
merged 1 commit into from
Jun 2, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -229,10 +229,12 @@ workflows:
parameters:
pattern:
- TestAcc_Aws
- TestAcc_Github_
- TestAcc_Google
- TestAcc_Azure_
- TestAcc_StateReader_

# Disable this rather than create a new test org
# - TestAcc_Github_
context:
- driftctl-acc
triggers:
Expand All @@ -252,10 +254,12 @@ workflows:
parameters:
pattern:
- TestAcc_Aws
- TestAcc_Github_
- TestAcc_Google
- TestAcc_Azure_
- TestAcc_StateReader_

# Disable this rather than create a new test org
# - TestAcc_Github_
context:
- driftctl-acc
pullrequest:
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,52 +5,52 @@ terraform {
}
}

data "github_user" "eliecharra" {
username = "eliecharra"
data "github_user" "craigfurman" {
username = "craigfurman"
}

resource "github_repository" "repo" {
count = 3
name = "repo${count.index}"
count = 3
name = "repo${count.index}"
auto_init = true
}

resource "github_branch" "repo_toto" {
count = 3
branch = "toto"
repository = github_repository.repo[count.index].name
count = 3
branch = "toto"
repository = github_repository.repo[count.index].name
source_branch = "main"
}

resource "github_branch_protection" "main_repo" {
count = 3
pattern = "main"
repository_id = github_repository.repo[count.index].name
count = 3
pattern = "main"
repository_id = github_repository.repo[count.index].name
enforce_admins = true
required_status_checks {
strict = false
strict = false
contexts = ["ci/travis"]
}

required_pull_request_reviews {
dismiss_stale_reviews = true
dismissal_restrictions = [
data.github_user.eliecharra.node_id
data.github_user.craigfurman.node_id
]
}

push_restrictions = [
data.github_user.eliecharra.node_id
data.github_user.craigfurman.node_id
]

allows_deletions = true
allows_deletions = true
allows_force_pushes = true
}


resource "github_branch_protection" "toto_repo" {
count = 3
repository_id = github_repository.repo[count.index].name
pattern = github_branch.repo_toto[count.index].branch
count = 3
repository_id = github_repository.repo[count.index].name
pattern = github_branch.repo_toto[count.index].branch
enforce_admins = true
}
Original file line number Diff line number Diff line change
Expand Up @@ -5,27 +5,47 @@ terraform {
}
}

data "github_user" "wbeuil" {
username = "wbeuil"
resource "github_team" "test" {
name = "acceptance-testing"
description = "Acceptance tests team"
}

data "github_user" "driftctl" {
username = "driftctl-acceptance-tester"
data "github_user" "karniwl" {
username = "karniwl"
}

resource "github_team" "foo" {
name = "foo"
description = "Foo team"
data "github_user" "chdorner-snyk" {
username = "chdorner-snyk"
}

resource "github_team_membership" "foo" {
team_id = github_team.foo.id
username = data.github_user.wbeuil.login
data "github_user" "agatakrajewska" {
username = "agatakrajewska"
}

data "github_user" "craigfurman" {
username = "craigfurman"
}

resource "github_team_membership" "karniwl" {
team_id = github_team.test.id
username = data.github_user.karniwl.login
role = "maintainer"
}

resource "github_team_membership" "chdorner-snyk" {
team_id = github_team.test.id
username = data.github_user.chdorner-snyk.login
role = "maintainer"
}

resource "github_team_membership" "agatakrajewska" {
team_id = github_team.test.id
username = data.github_user.agatakrajewska.login
role = "maintainer"
}

resource "github_team_membership" "bar" {
team_id = github_team.foo.id
username = data.github_user.driftctl.login
resource "github_team_membership" "craigfurman" {
team_id = github_team.test.id
username = data.github_user.craigfurman.login
role = "maintainer"
}