mirror of
https://github.com/prowler-cloud/prowler.git
synced 2026-10-30 23:34:27 +00:00
chore(security hub): improve securityhub_enabled check logic (#1851)
Co-authored-by: sergargar <sergargar@users.noreply.github.com>
This commit is contained in:
1 parent
28a978acc2
commit
54c16e3cdb
4 files changed
+147
-78
No files matched your search
@@ -30,6 +30,12 @@ def mock_make_api_call(self, operation_name, kwarg):
|
||||
},
|
||||
]
|
||||
}
|
||||
if operation_name == "ListEnabledProductsForImport":
|
||||
return {
|
||||
"ProductSubscriptions": [
|
||||
"arn:aws:securityhub:us-east-1:0123456789012:product-subscription/prowler/prowler",
|
||||
]
|
||||
}
|
||||
if operation_name == "DescribeHub":
|
||||
return {
|
||||
"HubArn": "arn:aws:securityhub:us-east-1:0123456789012:hub/default",
|
||||
@@ -74,4 +80,5 @@ class Test_SecurityHub_Service:
|
||||
== "arn:aws:securityhub:us-east-1:0123456789012:hub/default"
|
||||
)
|
||||
assert securityhub.securityhubs[0].id == "default"
|
||||
assert securityhub.securityhubs[0].standards == " cis-aws-foundations-benchmark"
|
||||
assert securityhub.securityhubs[0].standards == "cis-aws-foundations-benchmark "
|
||||
assert securityhub.securityhubs[0].integrations == "prowler "
|
||||
Reference in new issue
Block a user