Tidied updated tests.
[integration/test.git] / csit / libraries / KarafKeywords.robot
index f61e650d77a98ec9f552de1c760a60b9b09ad765..f1cc295755a3754a111b9595baf87351249ca309 100644 (file)
@@ -29,6 +29,14 @@ Issue Command On Karaf Console
     Log    ${output}
     [Return]    ${output}
 
+Check For Elements On Karaf Command Output Message
+    [Arguments]    ${cmd}    ${elements}    ${controller}=${ODL_SYSTEM_IP}    ${karaf_port}=${KARAF_SHELL_PORT}    ${timeout}=5
+    [Documentation]    Will execute the command using Issue Command On Karaf Console then check for the given elements
+    ...    in the command output message
+    ${output}    Issue Command On Karaf Console    ${cmd}    ${controller}    ${karaf_port}    ${timeout}
+    : FOR    ${i}    IN    @{elements}
+    \    Should Contain    ${output}    ${i}
+
 Verify Bundle Is Installed
     [Arguments]    ${bundle_name}    ${controller}=${ODL_SYSTEM_IP}    ${karaf_port}=${KARAF_SHELL_PORT}
     [Documentation]    Will succeed if the given ${bundle name} is present in the output of "bundle:list -s "