You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Scenario: Cancel a historical job returns "Conflict" response
22
-
Given operation "CancelHistoricalJob" enabled
23
-
And new "CancelHistoricalJob" request
21
+
Given new "CancelHistoricalJob" request
24
22
And request contains "job_id" parameter from "REPLACE.ME"
25
23
When the request is sent
26
24
Then the response status is 409 Conflict
27
25
28
26
@team:DataDog/k9-cloud-security-platform
29
27
Scenario: Cancel a historical job returns "Not Found" response
30
-
Given operation "CancelHistoricalJob" enabled
31
-
And new "CancelHistoricalJob" request
28
+
Given new "CancelHistoricalJob" request
32
29
And request contains "job_id" parameter with value "8e2a37fb-b0c8-4761-a7f0-0a8d6a98ba93"
33
30
When the request is sent
34
31
Then the response status is 404 Not Found
35
32
36
33
@team:DataDog/k9-cloud-security-platform
37
34
Scenario: Cancel a historical job returns "OK" response
38
-
Given operation "CancelHistoricalJob" enabled
39
-
And operation "RunHistoricalJob" enabled
40
-
And new "CancelHistoricalJob" request
35
+
Given new "CancelHistoricalJob" request
41
36
And there is a valid "historical_job" in the system
42
37
And request contains "job_id" parameter from "historical_job.data.id"
43
38
When the request is sent
@@ -93,24 +88,21 @@ Feature: Security Monitoring
93
88
94
89
@team:DataDog/k9-cloud-security-platform
95
90
Scenario: Convert a job result to a signal returns "Bad Request" response
96
-
Given operation "ConvertJobResultToSignal" enabled
97
-
And new "ConvertJobResultToSignal" request
91
+
Given new "ConvertJobResultToSignal" request
98
92
And body with value {"data": {"attributes": {"jobResultIds": [""], "notifications": [""], "signalMessage": "A large number of failed login attempts.", "signalSeverity": "critical"}, "type": "historicalDetectionsJobResultSignalConversion"}}
Scenario: Convert a job result to a signal returns "Not Found" response
104
-
Given operation "ConvertJobResultToSignal" enabled
105
-
And new "ConvertJobResultToSignal" request
98
+
Given new "ConvertJobResultToSignal" request
106
99
And body with value {"data": {"attributes": {"jobResultIds": [""], "notifications": [""], "signalMessage": "A large number of failed login attempts.", "signalSeverity": "critical"}, "type": "historicalDetectionsJobResultSignalConversion"}}
Scenario: Convert a job result to a signal returns "OK" response
112
-
Given operation "ConvertJobResultToSignal" enabled
113
-
And new "ConvertJobResultToSignal" request
105
+
Given new "ConvertJobResultToSignal" request
114
106
And body with value {"data": {"attributes": {"jobResultIds": [""], "notifications": [""], "signalMessage": "A large number of failed login attempts.", "signalSeverity": "critical"}, "type": "historicalDetectionsJobResultSignalConversion"}}
Scenario: Run a historical job returns "Bad Request" response
1009
-
Given operation "RunHistoricalJob" enabled
1010
-
And new "RunHistoricalJob" request
990
+
Given new "RunHistoricalJob" request
1011
991
And body with value {"data":{"type":"historicalDetectionsJobCreate","attributes":{"jobDefinition":{"type":"log_detection","name":"Excessive number of failed attempts.","queries":[{"query":"source:non_existing_src_weekend","aggregation":"count","groupByFields":[],"distinctFields":[]}],"cases":[{"name":"Condition 1","status":"info","notifications":[],"condition":"a > 1"}],"options":{"keepAlive":3600,"maxSignalDuration":86400,"evaluationWindow":900},"message":"A large number of failed login attempts.","tags":[],"from":1730387522611,"to":1730391122611,"index":"non_existing_index"}}}}
1012
992
When the request is sent
1013
993
Then the response status is 400 Bad Request
1014
994
1015
995
@team:DataDog/k9-cloud-security-platform
1016
996
Scenario: Run a historical job returns "Not Found" response
1017
-
Given operation "RunHistoricalJob" enabled
1018
-
And new "RunHistoricalJob" request
997
+
Given new "RunHistoricalJob" request
1019
998
And body with value {"data": { "type": "historicalDetectionsJobCreate", "attributes": {"fromRule": {"caseIndex": 0, "from": 1730201035064, "id": "non-existng", "index": "main", "notifications": [], "to": 1730204635115}}}}
1020
999
When the request is sent
1021
1000
Then the response status is 404 Not Found
1022
1001
1023
1002
@team:DataDog/k9-cloud-security-platform
1024
1003
Scenario: Run a historical job returns "Status created" response
1025
-
Given operation "RunHistoricalJob" enabled
1026
-
And new "RunHistoricalJob" request
1004
+
Given new "RunHistoricalJob" request
1027
1005
And body with value {"data":{"type":"historicalDetectionsJobCreate","attributes":{"jobDefinition":{"type":"log_detection","name":"Excessive number of failed attempts.","queries":[{"query":"source:non_existing_src_weekend","aggregation":"count","groupByFields":[],"distinctFields":[]}],"cases":[{"name":"Condition 1","status":"info","notifications":[],"condition":"a > 1"}],"options":{"keepAlive":3600,"maxSignalDuration":86400,"evaluationWindow":900},"message":"A large number of failed login attempts.","tags":[],"from":1730387522611,"to":1730387532611,"index":"main"}}}}
0 commit comments