Skip to content

Commit cb9ee82

Browse files
api-clients-generation-pipeline[bot]ci.datadog-api-spec
andauthored
Fix GCP CSPM test in Java (#1805)
Co-authored-by: ci.datadog-api-spec <[email protected]> Co-authored-by: api-clients-generation-pipeline[bot] <54105614+api-clients-generation-pipeline[bot]@users.noreply.github.com>
1 parent 81796b3 commit cb9ee82

5 files changed

+10
-9
lines changed

.apigentools-info

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -4,13 +4,13 @@
44
"spec_versions": {
55
"v1": {
66
"apigentools_version": "1.6.6",
7-
"regenerated": "2023-12-14 19:38:24.188378",
8-
"spec_repo_commit": "cdc82e06"
7+
"regenerated": "2023-12-15 15:50:51.303374",
8+
"spec_repo_commit": "56bcf717"
99
},
1010
"v2": {
1111
"apigentools_version": "1.6.6",
12-
"regenerated": "2023-12-14 19:38:24.201899",
13-
"spec_repo_commit": "cdc82e06"
12+
"regenerated": "2023-12-15 15:50:51.318688",
13+
"spec_repo_commit": "56bcf717"
1414
}
1515
}
1616
}

examples/v2/gcp-integration/CreateGCPSTSAccount_4235664992.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313
data=GCPSTSServiceAccountData(
1414
attributes=GCPSTSServiceAccountAttributes(
1515
is_cspm_enabled=True,
16+
resource_collection_enabled=True,
1617
client_email="[email protected]",
1718
host_filters=[],
1819
),
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
2023-12-13T21:29:09.202Z
1+
2023-12-15T08:45:38.020Z

tests/v2/cassettes/test_scenarios/test_create_a_new_entry_for_your_service_account_with_cspm_enabled_returns_ok_response.yaml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
interactions:
22
- request:
3-
body: '{"data":{"attributes":{"client_email":"dfb9f119aee90526@test-project.iam.gserviceaccount.com","host_filters":[],"is_cspm_enabled":true},"type":"gcp_service_account"}}'
3+
body: '{"data":{"attributes":{"client_email":"9f53cbf93a21704b@test-project.iam.gserviceaccount.com","host_filters":[],"is_cspm_enabled":true,"resource_collection_enabled":true},"type":"gcp_service_account"}}'
44
headers:
55
accept:
66
- application/json
@@ -10,7 +10,7 @@ interactions:
1010
uri: https://api.datadoghq.com/api/v2/integration/gcp/accounts
1111
response:
1212
body:
13-
string: '{"data":{"type":"gcp_service_account","attributes":{"is_security_command_center_enabled":false,"resource_collection_enabled":true,"is_cspm_enabled":true,"client_email":"dfb9f119aee90526@test-project.iam.gserviceaccount.com","account_tags":[],"automute":false,"host_filters":[]},"id":"d2ef6458-62a4-4fbe-ad48-9429baa01867"}}
13+
string: '{"data":{"type":"gcp_service_account","attributes":{"is_cspm_enabled":true,"account_tags":[],"host_filters":[],"resource_collection_enabled":true,"is_security_command_center_enabled":false,"client_email":"9f53cbf93a21704b@test-project.iam.gserviceaccount.com","automute":false},"id":"cf3c6e32-dad2-452e-8c09-f34c5f2211a1"}}
1414
1515
'
1616
headers:
@@ -25,7 +25,7 @@ interactions:
2525
accept:
2626
- '*/*'
2727
method: DELETE
28-
uri: https://api.datadoghq.com/api/v2/integration/gcp/accounts/d2ef6458-62a4-4fbe-ad48-9429baa01867
28+
uri: https://api.datadoghq.com/api/v2/integration/gcp/accounts/cf3c6e32-dad2-452e-8c09-f34c5f2211a1
2929
response:
3030
body:
3131
string: ''

tests/v2/features/gcp_integration.feature

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -67,7 +67,7 @@ Feature: GCP Integration
6767
@team:DataDog/gcp-integrations
6868
Scenario: Create a new entry for your service account with cspm enabled returns "OK" response
6969
Given new "CreateGCPSTSAccount" request
70-
And body with value {"data": {"attributes": {"is_cspm_enabled": true, "client_email": "{{ unique_hash }}@test-project.iam.gserviceaccount.com", "host_filters": []}, "type": "gcp_service_account"}}
70+
And body with value {"data": {"attributes": {"is_cspm_enabled": true, "resource_collection_enabled": true, "client_email": "{{ unique_hash }}@test-project.iam.gserviceaccount.com", "host_filters": []}, "type": "gcp_service_account"}}
7171
When the request is sent
7272
Then the response status is 201 OK
7373
And the response "data.type" is equal to "gcp_service_account"

0 commit comments

Comments
 (0)