mirror of
https://github.com/prowler-cloud/prowler.git
synced 2026-07-24 21:11:53 +00:00
fix(github): solve Github APP auth method (#8529)
This commit is contained in:
@@ -135,6 +135,7 @@ class TestGitHubProvider:
|
||||
"prowler.providers.github.github_provider.GithubProvider.setup_identity",
|
||||
return_value=GithubAppIdentityInfo(
|
||||
app_id=APP_ID,
|
||||
installations=["test-org"],
|
||||
),
|
||||
),
|
||||
):
|
||||
@@ -147,7 +148,9 @@ class TestGitHubProvider:
|
||||
|
||||
assert provider._type == "github"
|
||||
assert provider.session == GithubSession(token="", id=APP_ID, key=APP_KEY)
|
||||
assert provider.identity == GithubAppIdentityInfo(app_id=APP_ID)
|
||||
assert provider.identity == GithubAppIdentityInfo(
|
||||
app_id=APP_ID, installations=["test-org"]
|
||||
)
|
||||
assert provider._audit_config == {
|
||||
"inactive_not_archived_days_threshold": 180,
|
||||
}
|
||||
@@ -206,7 +209,9 @@ class TestGitHubProvider:
|
||||
),
|
||||
patch(
|
||||
"prowler.providers.github.github_provider.GithubProvider.setup_identity",
|
||||
return_value=GithubAppIdentityInfo(app_id=APP_ID),
|
||||
return_value=GithubAppIdentityInfo(
|
||||
app_id=APP_ID, installations=["test-org"]
|
||||
),
|
||||
),
|
||||
):
|
||||
connection = GithubProvider.test_connection(
|
||||
|
||||
Reference in New Issue
Block a user