X-Git-Url: https://git.opendaylight.org/gerrit/gitweb?a=blobdiff_plain;f=csit%2Flibraries%2FClusterManagement.robot;h=89d2f3371115e28b37f7f0a95058f4882226805e;hb=20fe8d97844f1ff5ce4fecef8e3e7def214137ba;hp=b2e0a8736116d78170099c8a4a6fc439a57759af;hpb=1a53ccd5414f993f13f26085946af29984b23ecb;p=integration%2Ftest.git diff --git a/csit/libraries/ClusterManagement.robot b/csit/libraries/ClusterManagement.robot index b2e0a87361..89d2f33711 100644 --- a/csit/libraries/ClusterManagement.robot +++ b/csit/libraries/ClusterManagement.robot @@ -846,3 +846,18 @@ Return_Member_IP ${member_int} = BuiltIn.Convert_To_Integer ${member_index} ${member_ip} = Collections.Get_From_Dictionary dictionary=${ClusterManagement__index_to_ip_mapping} key=${member_int} [Return] ${member_ip} + +Check Service Status + [Arguments] ${odl_ip} ${system_ready_state} ${service_state} @{service_list} + [Documentation] Issues the karaf shell command showSvcStatus to verify the ready and service states are the same as the arguments passed + ${service_status_output} = BuiltIn.Run Keyword If ${NUM_ODL_SYSTEM} > 1 KarafKeywords.Issue_Command_On_Karaf_Console showSvcStatus -n ${odl_ip} ${odl_ip} ${KARAF_SHELL_PORT} + ... ELSE KarafKeywords.Issue_Command_On_Karaf_Console showSvcStatus ${odl_ip} ${KARAF_SHELL_PORT} + BuiltIn.Should Contain ${service_status_output} ${system_ready_state} + : FOR ${service} IN @{service_list} + \ BuiltIn.Should Match Regexp ${service_status_output} ${service} +: ${service_state} + +Check Status of Services + [Arguments] @{service_list} + [Documentation] This keyword will verify whether all the services are operational in all the ODL nodes + : FOR ${i} IN RANGE ${NUM_ODL_SYSTEM} + \ ClusterManagement.Check Service Status ${ODL_SYSTEM_${i+1}_IP} ACTIVE OPERATIONAL @{service_list}