diff options
author | Peter Leitzen <pleitzen@gitlab.com> | 2019-07-03 04:31:27 +0300 |
---|---|---|
committer | Dan Davison <ddavison@gitlab.com> | 2019-07-03 04:31:27 +0300 |
commit | 72810bfcc3182ce7e987d8b0eaad0eb1de3646d3 (patch) | |
tree | d724f36b88cf839723a7b99f92586fce3bb70a4e /qa | |
parent | 66913cb291487f3bc01d5dc9b4d0ca3e71132846 (diff) |
Wait for 'Uninstall' when installing Prometheus
Prometheus is uninstallable so waiting won't see 'Install' at all.
We'll see 'Uninstall' instead.
Diffstat (limited to 'qa')
-rw-r--r-- | qa/qa/page/project/operations/kubernetes/show.rb | 8 | ||||
-rw-r--r-- | qa/qa/resource/kubernetes_cluster.rb | 2 |
2 files changed, 7 insertions, 3 deletions
diff --git a/qa/qa/page/project/operations/kubernetes/show.rb b/qa/qa/page/project/operations/kubernetes/show.rb index c81e13e9b91..4f625c5f0f0 100644 --- a/qa/qa/page/project/operations/kubernetes/show.rb +++ b/qa/qa/page/project/operations/kubernetes/show.rb @@ -28,12 +28,16 @@ module QA end end - def await_installed(application_name) + def await_installed(application_name, button_text: 'Installed') within(".js-cluster-application-row-#{application_name}") do - page.has_text?('Installed', wait: 300) + page.has_text?(button_text, wait: 300) end end + def await_uninstallable(application_name) + await_installed(application_name, button_text: 'Uninstall') + end + def ingress_ip # We need to wait longer since it can take some time before the # ip address is assigned for the ingress controller diff --git a/qa/qa/resource/kubernetes_cluster.rb b/qa/qa/resource/kubernetes_cluster.rb index 27ab7b60211..1dd93dd5b88 100644 --- a/qa/qa/resource/kubernetes_cluster.rb +++ b/qa/qa/resource/kubernetes_cluster.rb @@ -47,7 +47,7 @@ module QA page.install!(:runner) if @install_runner page.await_installed(:ingress) if @install_ingress - page.await_installed(:prometheus) if @install_prometheus + page.await_uninstallable(:prometheus) if @install_prometheus page.await_installed(:runner) if @install_runner if @install_ingress |