⏱️ Duration: 19.56s
❌ Error:
self = <tests.test_web_general.TestWebPhase1 object at 0x7f275d3d89a0>
login_page = <pages.login_page.LoginPage object at 0x7f275c3358a0>
main_page = <pages.main_page.MainPage object at 0x7f275c334610>
pricing_page = <pages.pricing_page.PricingPage object at 0x7f275c334520>
base_url = 'https://promo.com'
def test_w27_verify_header_for_logged_and_not_logged(
self, login_page, main_page, pricing_page, base_url
):
"""
W27 Verify header for logged and not logged
Pricing and PromoAI nav links should appear for guests and disappear
once the user is authenticated.
"""
page = login_page.page
# Unauthenticated: links should be present
main_page.go_to_homepage(base_url)
login_page.skip_cookies()
main_page.verify_header_links_visible()
page.goto(f"{base_url}/pricing")
page.wait_for_load_state("domcontentloaded")
main_page.verify_header_links_visible()
# Log in
login_page.login_directly(base_url, general_mail(), get_password())
# Authenticated: links should be gone
page.goto(f"{base_url}/create")
page.wait_for_load_state("domcontentloaded")
main_page.verify_header_links_not_visible()
page.goto(f"{base_url}/templates")
page.wait_for_load_state("domcontentloaded")
main_page.verify_header_links_not_visible()
page.goto(f"{base_url}/pricing")
page.wait_for_load_state("domcontentloaded")
> main_page.verify_header_links_not_visible()
tests/test_web_general.py:241:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
self = <pages.main_page.MainPage object at 0x7f275c334610>
def verify_header_links_not_visible(self):
"""
Checks that the Pricing and PromoAI nav links are absent (authenticated state).
Mirrors: verify_links_header(browser, False)
"""
> expect(self.page.locato
📸 Failure Screenshot: