Use _wait_for_spinner()

This useful method is currently present in repo, but unfortunately
unused. This patch use it where is necessary - after click to Submit btn
in several dialogues.

Change-Id: Ib9b51d864c5d3af958bc31a74266051c97456790
Partially implements blueprint: selenium-integration-testing
Closes-Bug: 1425250
This commit is contained in:
Martin Pavlasek 2015-02-24 20:06:35 +01:00 committed by Lin Hua Cheng
parent b0d74e7d3e
commit f97b9a9eb8
3 changed files with 6 additions and 0 deletions

View File

@ -72,12 +72,14 @@ class FlavorsPage(basepage.BaseNavigationPage):
self.create_flavor_form.ephemeral_disk.value = ephemeral_disk
self.create_flavor_form.swap_disk.value = swap_disk
self.create_flavor_form.submit.click()
self._wait_till_spinner_disappears()
def delete_flavor(self, name):
row = self._get_row_with_flavor_name(name)
row.mark()
self.flavors_table.delete_flavors.click()
self.confirm_delete_flavors_form.submit.click()
self._wait_till_spinner_disappears()
def is_flavor_present(self, name):
return bool(self._get_row_with_flavor_name(name))

View File

@ -71,12 +71,14 @@ class UsersPage(basepage.BaseNavigationPage):
self.create_user_form.project.text = project
self.create_user_form.role.text = role
self.create_user_form.submit.click()
self._wait_till_spinner_disappears()
def delete_user(self, name):
row = self._get_row_with_user_name(name)
row.mark()
self.users_table.delete_users.click()
self.confirm_delete_users_form.submit.click()
self._wait_till_spinner_disappears()
def is_user_present(self, name):
return bool(self._get_row_with_user_name(name))

View File

@ -91,12 +91,14 @@ class ImagesPage(basepage.BaseNavigationPage):
if is_protected:
self.create_image_form.protected.mark()
self.create_image_form.submit.click()
self._wait_till_spinner_disappears()
def delete_image(self, name):
row = self._get_row_with_image_name(name)
row.mark()
self.images_table.delete_images.click()
self.confirm_delete_images_form.submit.click()
self._wait_till_spinner_disappears()
def is_image_present(self, name):
return bool(self._get_row_with_image_name(name))