diff --git a/src/test/resources/features/tsa/policy/policy/import/POST.feature b/src/test/resources/features/tsa/policy/policy/import/POST.feature index 269f1095248273c7bbbd50be601df6cd6cfe09d2..b8fa00528aa65d180e04d788a62aba68e3765fef 100644 --- a/src/test/resources/features/tsa/policy/policy/import/POST.feature +++ b/src/test/resources/features/tsa/policy/policy/import/POST.feature @@ -1,9 +1,11 @@ #Copyright (c) 2023 Vereign AG [https://www.vereign.com] -@rest @all @tsa @policy @phase2 @IDM.TSA.E1.00005 @IDM.TSA.E1.00006 -Feature: API - TSA - policy - /export GET +@rest @all @tsa @policy @phase2 @IDM.TSA.E1.00005 @IDM.TSA.E1.00006 @IDM.TSA.E1.00056 + +Feature: API - TSA - policy - /import GET As user - I want to be able to import policy + I want to be able to export signed policy + then I want to be able to check the signature and if the policy is not modified to import it So I can use it Background: @@ -11,13 +13,26 @@ Feature: API - TSA - policy - /export GET @wip Scenario: TSA - Import specific policy - Positive + When I Export Policy group {example} name {examplePolicy} version {1.4} When I Import {policies_example_examplePolicy_1.4.zip} in to Policy Then the status code should be {200} And I execute the Policy group {example} name {examplePolicy} version {1.4} via TSA Policy API Then the status code should be {200} @negative @wip - Scenario: TSA - Import modified policy - Negative + Scenario Outline: TSA - Import modified policy with modified file <modifiedFile> - Negative + When I Export Policy group {example} name {examplePolicy} version {1.4} + Then I extract the content + And modify file <modifiedFile> + And I archive back all files from the bundle When I Import {policies_example_modifiedPolicy_1.4.zip} in to Policy Then the status code should be {403} And the field {message} contains the value {failed to verify bundle} + + Examples: + | modifiedFile | + | data-config.json | + | data.json | + | export-config.json | + | export-config.json | + | export-config.json | diff --git a/src/test/resources/features/tsa/policy/policy/{respository}/{group}/{name}/{version}/export/GET.feature b/src/test/resources/features/tsa/policy/policy/{respository}/{group}/{name}/{version}/export/GET.feature index 3f1698290fe6aec6d4d5f406981608a4a7ab1849..0953b05f6cf60185013710538cc9f0aab1066d67 100644 --- a/src/test/resources/features/tsa/policy/policy/{respository}/{group}/{name}/{version}/export/GET.feature +++ b/src/test/resources/features/tsa/policy/policy/{respository}/{group}/{name}/{version}/export/GET.feature @@ -1,6 +1,6 @@ #Copyright (c) 2023 Vereign AG [https://www.vereign.com] -@rest @all @tsa @policy @phase2 @IDM.TSA.E1.00005 @IDM.TSA.E1.00006 @IDM.TSA.E1.00011 +@rest @all @tsa @policy @phase2 @IDM.TSA.E1.00005 @IDM.TSA.E1.00006 @IDM.TSA.E1.00011 @IDM.TSA.E1.00056 Feature: API - TSA - policy - {repository}/{group}/{name}/{version}/export GET As user I want to be able to export policy