Scheduled weekly dependency update for week 16 (#458)

* Update pypom from 1.3.0 to 2.0.0

* Use loaded property in pages instead of overriding wait_for_page_to_load
This commit is contained in:
pyup.io bot 2018-04-23 20:27:38 +02:00 коммит произвёл Stephen Donner
Родитель 8d80b99203
Коммит 16eeed5582
6 изменённых файлов: 18 добавлений и 16 удалений

Просмотреть файл

@ -15,7 +15,7 @@ BeautifulSoup = "==3.2.1"
flake8 = "==3.5.0"
flake8-isort = "==2.5"
mozlog = "==3.7"
PyPOM = "==1.3.0"
PyPOM = "==2.0.0"
pytest = "==3.5.0"
pytest-metadata = "==1.7.0"
pytest-selenium = "==1.12.0"

Просмотреть файл

@ -17,9 +17,9 @@ class EditGroupPage(Base):
_invitations_button_locator = (By.ID, 'invitations-tab')
_invitations_tab_locator = (By.ID, 'invitations')
def wait_for_page_to_load(self):
self.wait.until(lambda s: self.is_element_displayed(*self._description_button_locator))
return self
@property
def loaded(self):
return self.is_element_displayed(*self._description_button_locator)
@property
def description(self):

Просмотреть файл

@ -14,9 +14,10 @@ class GroupInfoPage(Base):
_description_locator = (By.CSS_SELECTOR, '.group-description')
_irc_channel_locator = (By.ID, 'group-irc')
def wait_for_page_to_load(self):
self.wait.until(lambda _: self.find_element(By.CSS_SELECTOR, 'html.js body#group-show'))
return self
@property
def loaded(self):
return self.is_element_present(
By.CSS_SELECTOR, 'html.js body#group-show')
def delete_group(self):
self.wait.until(expected.visibility_of_element_located(

Просмотреть файл

@ -28,9 +28,9 @@ class Profile(Base):
_profile_message_locator = (By.CSS_SELECTOR, '.alert')
_view_as_locator = (By.ID, 'view-privacy-mode')
def wait_for_page_to_load(self):
self.wait.until(lambda _: self.find_element(By.CSS_SELECTOR, 'html.js body#profile'))
return self
@property
def loaded(self):
return self.is_element_present(By.CSS_SELECTOR, 'html.js body#profile')
def view_profile_as(self, view_as):
element = self.find_element(*self._view_as_locator)

Просмотреть файл

@ -27,9 +27,10 @@ class Register(Base):
_city_results_list_locator = (By.CSS_SELECTOR, '#select2-id_city-results > li.select2-results__option--highlighted')
_first_city_search_result_locator = (By.CSS_SELECTOR, '#select2-id_city-results > li.select2-results__option--highlighted:first-child')
def wait_for_page_to_load(self):
self.wait.until(lambda _: self.find_element(By.CSS_SELECTOR, 'html.js body#edit-profile'))
return self
@property
def loaded(self):
return self.is_element_present(
By.CSS_SELECTOR, 'html.js body#edit-profile')
@property
def privacy_error_message(self):

Просмотреть файл

@ -22,9 +22,9 @@ class Search(Base):
_last_page_number_locator = (By.CSS_SELECTOR, '#pagination-form select option:last-child')
_group_name_locator = (By.CSS_SELECTOR, '.group-name')
def wait_for_page_to_load(self):
self.wait.until(lambda _: self.find_element(By.CSS_SELECTOR, 'html.js body#search'))
return self
@property
def loaded(self):
return self.is_element_present(By.CSS_SELECTOR, 'html.js body#search')
@property
def results_count(self):