aboutsummaryrefslogtreecommitdiffstats
path: root/tests/oom-platform-cert-service/postprocessor/resources/test-keywords.robot
diff options
context:
space:
mode:
authorKrzysztof Kuzmicki <krzysztof.kuzmicki@nokia.com>2020-09-23 08:10:30 +0000
committerGerrit Code Review <gerrit@onap.org>2020-09-23 08:10:30 +0000
commitae2557a38de9d241bd331de8fa6095b956698927 (patch)
treef259c831d8b0dd62989e667a9574ddde5c1eaf66 /tests/oom-platform-cert-service/postprocessor/resources/test-keywords.robot
parent63b81b47402308e77b26bafbfd32e7f6c6f62320 (diff)
parente0da464c1b8bfe7ceb1f16879a2c550e7348fe18 (diff)
Merge "[OOM-CMPv2] Rename truststoremerger->postprocessor"
Diffstat (limited to 'tests/oom-platform-cert-service/postprocessor/resources/test-keywords.robot')
-rw-r--r--tests/oom-platform-cert-service/postprocessor/resources/test-keywords.robot44
1 files changed, 44 insertions, 0 deletions
diff --git a/tests/oom-platform-cert-service/postprocessor/resources/test-keywords.robot b/tests/oom-platform-cert-service/postprocessor/resources/test-keywords.robot
new file mode 100644
index 00000000..514e2391
--- /dev/null
+++ b/tests/oom-platform-cert-service/postprocessor/resources/test-keywords.robot
@@ -0,0 +1,44 @@
+*** Settings ***
+
+Resource ../../../common.robot
+Resource ./test-properties.robot
+Library ../libraries/TrustMergerManager.py ${MOUNT_PATH} ${TRUSTSTORES_PATH}
+Library ../libraries/JksValidator.py
+Library ../libraries/PemTruststoreValidator.py
+
+*** Keywords ***
+
+Run Trust Merger And Expect Error
+ [Documentation] Run Truststore Merger Container And Validate Exit Code
+ [Arguments] ${env_file} ${expected_exit_code}
+ ${exit_code}= Run Merger Container ${DOCKER_MERGER_IMAGE} ${MERGER_CONTAINER_NAME} ${env_file}
+ Remove Merger Container And Save Logs ${MERGER_CONTAINER_NAME} negative_path
+ Should Be Equal As Strings ${exit_code} ${expected_exit_code} Client return unexpected exit code return: ${exitcode} , but expected: ${expected_exit_code}
+
+Run Trust Merger And Merge Truststore Files To Jks
+ [Documentation] Run Truststore Merger Container And Validate Exit Code And Provided Truststore Files
+ [Arguments] ${env_file} ${expected_exit_code} ${jks_path} ${jks_password} ${expected_jks_path}
+ ${exit_code}= Run Merger Container ${DOCKER_MERGER_IMAGE} ${MERGER_CONTAINER_NAME} ${env_file}
+ ${files_equal}= Assert Jks Truststores Equal ${jks_path} ${jks_password} ${expected_jks_path}
+ Remove Merger Container And Save Logs ${MERGER_CONTAINER_NAME} positive_path
+ Should Be Equal As Strings ${exit_code} ${expected_exit_code} Client return unexpected exit code return: ${exitcode} , but expected: ${expected_exit_code}
+ Should Be True ${files_equal}
+
+Run Trust Merger And Check Copied Keystore Files
+ [Documentation] Run Truststore Merger Container And Validate Exit Code And Provided Keystore Files
+ [Arguments] ${env_file} ${expected_exit_code} ${jks_path} ${jks_password} ${expected_jks_path}
+ ${exit_code}= Run Merger Container ${DOCKER_MERGER_IMAGE} ${MERGER_CONTAINER_NAME} ${env_file}
+ ${files_equal}= Assert Jks Keystores Equal ${jks_path} ${jks_password} ${expected_jks_path}
+ Remove Merger Container And Save Logs ${MERGER_CONTAINER_NAME} positive_path
+ Should Be Equal As Strings ${exit_code} ${expected_exit_code} Client return unexpected exit code return: ${exitcode} , but expected: ${expected_exit_code}
+ Should Be True ${files_equal}
+
+Run Trust Merger And Merge Truststore Files To Pem
+ [Documentation] Run Truststore Merger Container And Validate Exit Code And Files
+ [Arguments] ${env_file} ${expected_exit_code} ${pem_path} ${expected_pem_path}
+ ${exit_code}= Run Merger Container ${DOCKER_MERGER_IMAGE} ${MERGER_CONTAINER_NAME} ${env_file}
+ ${files_equal}= Assert Pem Truststores Equal ${pem_path} ${expected_pem_path}
+ Remove Merger Container And Save Logs ${MERGER_CONTAINER_NAME} positive_path
+ Should Be Equal As Strings ${exit_code} ${expected_exit_code} Client return unexpected exit code return: ${exitcode} , but expected: ${expected_exit_code}
+ Should Be True ${files_equal}
+