diff --git a/.generator/schemas/v2/openapi.yaml b/.generator/schemas/v2/openapi.yaml index fa9ffba157..685e6771f0 100644 --- a/.generator/schemas/v2/openapi.yaml +++ b/.generator/schemas/v2/openapi.yaml @@ -166732,6 +166732,14 @@ paths: $ref: "#/components/responses/ForbiddenResponse" "404": $ref: "#/components/responses/NotFoundResponse" + "409": + $ref: "#/components/responses/ConflictResponse" + "412": + content: + application/json: + schema: + $ref: "#/components/schemas/APIErrorResponse" + description: Precondition Failed "429": $ref: "#/components/responses/TooManyRequestsResponse" "500": @@ -166846,6 +166854,14 @@ paths: $ref: "#/components/responses/ForbiddenResponse" "404": $ref: "#/components/responses/NotFoundResponse" + "409": + $ref: "#/components/responses/ConflictResponse" + "412": + content: + application/json: + schema: + $ref: "#/components/schemas/APIErrorResponse" + description: Precondition Failed "429": $ref: "#/components/responses/TooManyRequestsResponse" "500": diff --git a/tests/v2/features/reference_tables.feature b/tests/v2/features/reference_tables.feature index 859f70c13e..7e0b963070 100644 --- a/tests/v2/features/reference_tables.feature +++ b/tests/v2/features/reference_tables.feature @@ -82,6 +82,14 @@ Feature: Reference Tables When the request is sent Then the response status is 400 Bad Request + @generated @skip @team:DataDog/redapl-experiences + Scenario: Delete rows returns "Conflict" response + Given new "DeleteRows" request + And request contains "id" parameter from "REPLACE.ME" + And body with value {"data": [{"id": "primary_key_value", "type": "row"}]} + When the request is sent + Then the response status is 409 Conflict + @generated @skip @team:DataDog/redapl-experiences Scenario: Delete rows returns "Not Found" response Given new "DeleteRows" request @@ -90,6 +98,14 @@ Feature: Reference Tables When the request is sent Then the response status is 404 Not Found + @generated @skip @team:DataDog/redapl-experiences + Scenario: Delete rows returns "Precondition Failed" response + Given new "DeleteRows" request + And request contains "id" parameter from "REPLACE.ME" + And body with value {"data": [{"id": "primary_key_value", "type": "row"}]} + When the request is sent + Then the response status is 412 Precondition Failed + @generated @skip @team:DataDog/redapl-experiences Scenario: Delete rows returns "Rows deleted successfully" response Given new "DeleteRows" request @@ -208,6 +224,14 @@ Feature: Reference Tables When the request is sent Then the response status is 400 Bad Request + @generated @skip @team:DataDog/redapl-experiences + Scenario: Upsert rows returns "Conflict" response + Given new "UpsertRows" request + And request contains "id" parameter from "REPLACE.ME" + And body with value {"data": [{"attributes": {"values": {}}, "id": "primary_key_value", "type": "row"}]} + When the request is sent + Then the response status is 409 Conflict + @generated @skip @team:DataDog/redapl-experiences Scenario: Upsert rows returns "Not Found" response Given new "UpsertRows" request @@ -216,6 +240,14 @@ Feature: Reference Tables When the request is sent Then the response status is 404 Not Found + @generated @skip @team:DataDog/redapl-experiences + Scenario: Upsert rows returns "Precondition Failed" response + Given new "UpsertRows" request + And request contains "id" parameter from "REPLACE.ME" + And body with value {"data": [{"attributes": {"values": {}}, "id": "primary_key_value", "type": "row"}]} + When the request is sent + Then the response status is 412 Precondition Failed + @generated @skip @team:DataDog/redapl-experiences Scenario: Upsert rows returns "Rows created or updated successfully" response Given new "UpsertRows" request