X-Git-Url: https://osm.etsi.org/gitweb/?a=blobdiff_plain;f=robot-systest%2Flib%2Fvim_lib.robot;h=a156a9e04ac3892ab5036817e12a75bbc98cc263;hb=15589053373c07bea08a52a6fc8dbcd6d80603ac;hp=b6c452f33f36eae9b1178363ded7ccbb0892f083;hpb=f96bb45c0a03f2188688d90d67ea718851cec2de;p=osm%2Ftests.git diff --git a/robot-systest/lib/vim_lib.robot b/robot-systest/lib/vim_lib.robot index b6c452f..a156a9e 100644 --- a/robot-systest/lib/vim_lib.robot +++ b/robot-systest/lib/vim_lib.robot @@ -24,7 +24,7 @@ Resource %{ROBOT_DEVOPS_FOLDER}/lib/prometheus_lib.robot ${success_return_code} 0 ${delete_max_wait_time} 1min ${delete_pol_time} 15sec -${vim_status_max_wait_time} 1min +${vim_status_max_wait_time} 2min ${vim_status_pol_time} 15sec @@ -70,6 +70,13 @@ Check for VIM Target Should Not Be Equal As Strings ${stdout} ${vim_name} +Check for VIM Target Metric + [Arguments] ${vim_name} ${prometheus_host} ${prometheus_port} + + ${vim_account_id}= Get VIM Target ID ${vim_name} + Wait Until Keyword Succeeds ${vim_status_max_wait_time} ${vim_status_pol_time} Check If VIM Target Has Metric ${vim_account_id} ${prometheus_host} ${prometheus_port} + + Check for VIM Target Status [Arguments] ${vim_name} ${prometheus_host} ${prometheus_port} @@ -91,3 +98,10 @@ Check If VIM Target Is Available ${metric}= Get Metric ${prometheus_host} ${prometheus_port} osm_vim_status vim_account_id=${vim_account_id} Should Be Equal As Integers ${metric} 1 msg=VIM Target '${vim_account_id}' is not active values=false + + +Check If VIM Target Has Metric + [Arguments] ${vim_account_id} ${prometheus_host} ${prometheus_port} + + ${metric}= Get Metric ${prometheus_host} ${prometheus_port} osm_vim_status vim_account_id=${vim_account_id} + Should Be True ${metric} <2 msg=VIM Target '${vim_account_id}' has no metric