Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 6 additions & 2 deletions pages/exercises_ru_words_family_page.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,10 @@ def check_elements_visibility_on_6th_level(self):
@allure.step("Get structure of the 7th level of nesting on the page")
def get_structure_of_7th_level(self):
elements = self.elements_are_present(self.locators.PAGE_SEVENTH_LEVEL_ELEMENTS)
tags = [element.tag_name for element in elements]
print(*tags, sep='\n')
# tags = [element.tag_name for element in elements]
# print(*tags, sep='\n')
return elements

@allure.step("Check if elements of the 7th level of nesting are visible")
def check_elements_visibility_on_7th_level(self):
return all(element.is_displayed() for element in self.get_structure_of_7th_level())
2 changes: 2 additions & 0 deletions tests/exercises_ru_words_family_page_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ def test_erwf_01_02_verify_page_structure_and_visibility(self, driver, exercises
structure_of_6th_level = page.get_structure_of_6th_level()
visibility_of_elements_on_6th_level = page.check_elements_visibility_on_6th_level()
structure_of_7th_level = page.get_structure_of_7th_level()
visibility_of_elements_on_7th_level = page.check_elements_visibility_on_7th_level()
assert structure_of_1st_level, "The page is empty"
assert visibility_of_elements_on_1st_level, "1th-level elements are invisible"
assert structure_of_2nd_level, "Elements on the 2nd level are absent on the page"
Expand All @@ -42,3 +43,4 @@ def test_erwf_01_02_verify_page_structure_and_visibility(self, driver, exercises
assert structure_of_6th_level, "Elements on the 6th level are absent on the page"
assert visibility_of_elements_on_6th_level, "6th-level elements are invisible"
assert structure_of_7th_level, "Elements on the 7th level are absent on the page"
assert visibility_of_elements_on_7th_level, "7th-level elements are invisible"
Loading