From a5cb230b7e265ea7833e54ea19ccac4525b49843 Mon Sep 17 00:00:00 2001 From: Alena Krauch Date: Wed, 1 Apr 2026 11:21:50 +0300 Subject: [PATCH] ref test_su_02.02 Verifying page titles update start_unauthorized_page.py, start_unauthorized_page_data.py, used_resources_page.py, #209 --- pages/start_unauthorized_page.py | 5 ++++- pages/used_resources_page.py | 10 ++-------- test_data/start_unauthorized_page_data.py | 4 ++-- 3 files changed, 8 insertions(+), 11 deletions(-) diff --git a/pages/start_unauthorized_page.py b/pages/start_unauthorized_page.py index 3b7a9deda8..f545ad734b 100644 --- a/pages/start_unauthorized_page.py +++ b/pages/start_unauthorized_page.py @@ -88,7 +88,10 @@ def get_list_of_titles(self): @allure.step("Get the list of title values") def get_values_of_titles(self): - return [title.text for title in self.get_list_of_titles()] + titles = [title.text for title in self.get_list_of_titles()] + print(*titles, len(titles), sep='\n') + return titles + # return [title.text for title in self.get_list_of_titles()] @allure.step("Get the list of subtitles h4 on the page") def get_list_of_subtitles(self): diff --git a/pages/used_resources_page.py b/pages/used_resources_page.py index dc3c33d15d..7ac7121a05 100644 --- a/pages/used_resources_page.py +++ b/pages/used_resources_page.py @@ -115,17 +115,11 @@ def get_list_of_icons(self): @allure.step("Check all icons on the page are visible") def check_icons_visibility(self): - visible_icons = self.get_list_of_icons()[2:] - print(len(visible_icons)) - return all(icon.is_displayed() for icon in visible_icons) - # return all(icon.is_displayed() for icon in self.get_list_of_icons()) + return all(icon.is_displayed() for icon in self.get_list_of_icons()[2:]) @allure.step("Get attribute 'xmlns' of icons on the page") def get_icons_xmlns(self): - icons_xmlns = [icon.get_attribute('xmlns') for icon in self.get_list_of_icons()[2:]] - print(*icons_xmlns, len(icons_xmlns), sep='\n') - return icons_xmlns - # return [icon.get_attribute('xmlns') for icon in self.get_list_of_icons()] + return [icon.get_attribute('xmlns') for icon in self.get_list_of_icons()[2:]] @allure.step("Get the list of sizes of icons") def get_icons_sizes(self): diff --git a/test_data/start_unauthorized_page_data.py b/test_data/start_unauthorized_page_data.py index ecfa7f1c87..7ba0c04c94 100644 --- a/test_data/start_unauthorized_page_data.py +++ b/test_data/start_unauthorized_page_data.py @@ -7,8 +7,8 @@ class StartUnauthorizedPageData: tab_title = "BrainUp" - page_titles = ("BrainUP - онлайн занятия для детей и взрослых", "Преимущества", - "BrainUP - online classes for children and adults", "Advantages") + page_titles = ("BrainUP - онлайн занятия для детей и взрослых", "Преимущества", "Отзыв специалиста", + "BrainUP - online classes for children and adults", "Advantages", "Expert Feedback") page_subtitles = ("BRAINUP", "ОНЛАЙН ЗАНЯТИЯ", "РАЗВИТИЕ", "ONLINE LESSONS", "SELF-DEVELOPMENT")