mirror of
https://github.com/prowler-cloud/prowler.git
synced 2026-10-30 23:34:27 +00:00
feat: pat and oauth authentication with and without flags
This commit is contained in:
5 files changed
+99
-42
No files matched your search
@@ -14,7 +14,7 @@ TOKEN = "github-token"
|
||||
|
||||
# Mocked GitHub Provider
|
||||
def set_mocked_github_provider(
|
||||
auth_method: str = "personal_access_token",
|
||||
auth_method: str = "personal_access",
|
||||
credentials: GithubSession = GithubSession(token=TOKEN),
|
||||
identity: GithubIdentityInfo = GithubIdentityInfo(
|
||||
account_name=ACCOUNT_NAME,
|
||||
|
||||
@@ -17,7 +17,7 @@ from tests.providers.github.github_fixtures import (
|
||||
class TestGitHubProvider:
|
||||
def test_github_provider(self):
|
||||
# We need to set exactly one auth method
|
||||
personal_access_token = True
|
||||
personal_access = True
|
||||
oauth_app = False
|
||||
github_app = False
|
||||
fixer_config = load_and_validate_config_file(
|
||||
@@ -36,7 +36,7 @@ class TestGitHubProvider:
|
||||
),
|
||||
):
|
||||
provider = GithubProvider(
|
||||
personal_access_token,
|
||||
personal_access,
|
||||
github_app,
|
||||
oauth_app,
|
||||
)
|
||||
|
||||
Reference in new issue
Block a user