From e808833fd40495eadea7649fcab096c22b5f4ebf Mon Sep 17 00:00:00 2001 From: Alena Krauch Date: Wed, 24 Jun 2026 16:25:22 +0300 Subject: [PATCH 1/2] ref test_hpa_03.03.01_verify_auth_Telegram_links_navigation update header_test.py, header_page.py #268 --- pages/header_page.py | 15 ++++++++++++++- tests/header_test.py | 15 +++++++++------ 2 files changed, 23 insertions(+), 7 deletions(-) diff --git a/pages/header_page.py b/pages/header_page.py index b2b24418f6..5f128ad17c 100644 --- a/pages/header_page.py +++ b/pages/header_page.py @@ -437,12 +437,25 @@ def click_on_auth_external_links_in_header(self): print(*opened_pages) return opened_pages - @allure.step("Click on the 'Telegram' link for authorized user") + @allure.step("Click on the 'Telegram' link #1 for authorized user") def click_on_Telegram_link_auth1(self): self.element_is_present_and_clickable(self.locators1.LINK_TELEGRAM_AUTH).click() self.driver.switch_to.window(self.driver.window_handles[1]) current_tab_url = self.get_current_tab_url() print(current_tab_url) + self.driver.switch_to.window(self.driver.window_handles[0]) + print(self.get_current_tab_url()) + return current_tab_url + + @allure.step("Click on the 'Telegram' link #2 for authorized user") + def click_on_Telegram_link_auth2(self): + self.click_more_button() + self.element_is_present_and_clickable(self.locators1.LINK_TELEGRAM_AUTH2).click() + self.driver.switch_to.window(self.driver.window_handles[1]) + current_tab_url = self.get_current_tab_url() + print(current_tab_url) + self.driver.switch_to.window(self.driver.window_handles[0]) + print(self.get_current_tab_url()) return current_tab_url diff --git a/tests/header_test.py b/tests/header_test.py index faab6b98be..acefade56c 100644 --- a/tests/header_test.py +++ b/tests/header_test.py @@ -350,7 +350,7 @@ def test_hpa_03_02_1_verify_auth_direct_internal_links_navigation(self, driver, assert all(element in hPD.set_auth for element in opened_pages), \ "Some of direct internal links lead to incorrect pages after clicking" - @pytest.mark.skip("Unstable test environment") + # @pytest.mark.skip("Unstable test environment") @allure.title("""Verify if external links in the Header for an authorized user lead to correct pages after click""") def test_hpa_03_03_verify_auth_external_links_lead_to_proper_pages(self, driver, auto_test_user_authorized): @@ -361,12 +361,15 @@ def test_hpa_03_03_verify_auth_external_links_lead_to_proper_pages(self, driver, assert all(element in hPD.set_auth for element in opened_pages), \ "Some of external links lead to incorrect pages after clicking" - @allure.title("""Verify if external Telegram link #1 in the Header for an authorized user - leads to a correct page after click""") - def test_hpa_03_03_01_verify_auth_Telegram_link1_navigation(self, driver, auto_test_user_authorized): + @allure.title("""Verify if external Telegram links #1,2 in the Header for an authorized user + lead to the correct page after click""") + def test_hpa_03_03_01_verify_auth_telegram_links_navigation(self, driver, auto_test_user_authorized): page = hPage(driver) - opened_page = page.click_on_Telegram_link_auth1() - assert opened_page in hPD.set_auth, "The Telegram link leads to an incorrect page after clicking" + opened_page1 = page.click_on_Telegram_link_auth1() + opened_page2 = page.click_on_Telegram_link_auth2() + assert opened_page1 in hPD.set_auth, "The Telegram link #1 leads to an incorrect page after clicking" + assert opened_page2 in hPD.set_auth, "The Telegram link #2 leads to an incorrect page after clicking" + assert opened_page1 == opened_page2, "The Telegram links #1,2 are the same" @allure.title("""Verify that the Logo link on the Start Authorized Page refreshes the current page and doesn't lead to other pages after clicking""") From 4e6ef7c764a0aa27cf8b36466caf89beb9fd47ea Mon Sep 17 00:00:00 2001 From: Alena Krauch Date: Wed, 24 Jun 2026 16:27:41 +0300 Subject: [PATCH 2/2] ref test_hpa_03.03.01_verify_auth_Telegram_links_navigation update header_test.py, header_page.py #268 --- tests/header_test.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tests/header_test.py b/tests/header_test.py index acefade56c..65c34e88b2 100644 --- a/tests/header_test.py +++ b/tests/header_test.py @@ -350,7 +350,7 @@ def test_hpa_03_02_1_verify_auth_direct_internal_links_navigation(self, driver, assert all(element in hPD.set_auth for element in opened_pages), \ "Some of direct internal links lead to incorrect pages after clicking" - # @pytest.mark.skip("Unstable test environment") + @pytest.mark.skip("Unstable test environment") @allure.title("""Verify if external links in the Header for an authorized user lead to correct pages after click""") def test_hpa_03_03_verify_auth_external_links_lead_to_proper_pages(self, driver, auto_test_user_authorized):