Fix Bug 2197 - Prometheus cannot be authenticated in Robot tests
Change-Id: I1c610968fea5f13711d6d6d8bed5ddc7422a6d3f
Signed-off-by: Guillermo Calvino <guillermo.calvino@canonical.com>
(cherry picked from commit 063677c719bd33d8674903ed5b7f11e7368da23a)
diff --git a/robot-systest/lib/vim_lib.robot b/robot-systest/lib/vim_lib.robot
index 8fd7e51..bfaae36 100644
--- a/robot-systest/lib/vim_lib.robot
+++ b/robot-systest/lib/vim_lib.robot
@@ -73,17 +73,17 @@
Check for VIM Target Metric
- [Arguments] ${vim_name} ${prometheus_host} ${prometheus_port}
+ [Arguments] ${vim_name} ${prometheus_host} ${prometheus_port} ${prometheus_user} ${prometheus_password}
${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}
+ 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} ${prometheus_user} ${prometheus_password}
Check for VIM Target Status
- [Arguments] ${vim_name} ${prometheus_host} ${prometheus_port}
+ [Arguments] ${vim_name} ${prometheus_host} ${prometheus_port} ${prometheus_user} ${prometheus_password}
${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 Is Available ${vim_account_id} ${prometheus_host} ${prometheus_port}
+ Wait Until Keyword Succeeds ${vim_status_max_wait_time} ${vim_status_pol_time} Check If VIM Target Is Available ${vim_account_id} ${prometheus_host} ${prometheus_port} ${prometheus_user} ${prometheus_password}
Get VIM Target ID
@@ -110,14 +110,14 @@
Check If VIM Target Is Available
- [Arguments] ${vim_account_id} ${prometheus_host} ${prometheus_port}
+ [Arguments] ${vim_account_id} ${prometheus_host} ${prometheus_port} ${prometheus_user} ${prometheus_password}
- ${metric}= Get Metric ${prometheus_host} ${prometheus_port} osm_vim_status vim_account_id=${vim_account_id}
+ ${metric}= Get Metric ${prometheus_host} ${prometheus_port} ${prometheus_user} ${prometheus_password} 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}
+ [Arguments] ${vim_account_id} ${prometheus_host} ${prometheus_port} ${prometheus_user} ${prometheus_password}
- ${metric}= Get Metric ${prometheus_host} ${prometheus_port} osm_vim_status vim_account_id=${vim_account_id}
+ ${metric}= Get Metric ${prometheus_host} ${prometheus_port} ${prometheus_user} ${prometheus_password} osm_vim_status vim_account_id=${vim_account_id}
Should Be True ${metric} <2 msg=VIM Target '${vim_account_id}' has no metric