From 6fc13a121dbe4be3461baf2b926d1210efc872dc Mon Sep 17 00:00:00 2001 From: "georgi.michev" <georgi.michev@vereign.com> Date: Thu, 25 Aug 2022 11:36:04 +0300 Subject: [PATCH] Add new negative test and insert tags Signed-off-by: georgi.michev <georgi.michev@vereign.com> --- .../features/tsa/signer/v1/presentation/POST.feature | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/test/resources/features/tsa/signer/v1/presentation/POST.feature b/src/test/resources/features/tsa/signer/v1/presentation/POST.feature index 8c193ea5..28720e06 100644 --- a/src/test/resources/features/tsa/signer/v1/presentation/POST.feature +++ b/src/test/resources/features/tsa/signer/v1/presentation/POST.feature @@ -38,6 +38,7 @@ Feature: API - TSA - Signer create presentation from JSON - v1/presentation POST | multi data | multi | Signer_JSON_multi_schema.json | | with context | context | Signer_JSON_context_schema.json | + @negative Scenario Outline: TSA - create presentation from JSON <labelSuffix> - Negative When I load the REST request {Data.json} with profile {<profileOption>} And I create presentation from JSON via TSA Signer API @@ -51,3 +52,11 @@ Feature: API - TSA - Signer create presentation from JSON - v1/presentation POST | missing data field | missing_data | "data" is missing from body | | blank data | blank_data | invalid or missing credentials data | | wrong format | data_format | json: cannot unmarshal string into Go struct field | + + @negative + Scenario: TSA - create presentation from JSON with invalid body - Negative + When I set the following request body {{"data":[{"text": "some text"}}} + And I create presentation from JSON via TSA Signer API + Then the status code should be {400} + And the response is valid according to the {Signer_GetKey_negative_schema.json} REST schema + And the field {message} contains the value {invalid character} -- GitLab