⏱️ Duration: 150.35s
❌ Error:
self = <tests.test_web_general.TestWebPhase1 object at 0x7fecb6ecc6d0>
main_page = <pages.main_page.MainPage object at 0x7fecb5efc160>
@pytest.mark.skip_testenv
@pytest.mark.skip_smoke
@pytest.mark.skip_sanity
def test_w26_promo_performance_tests(self, main_page):
"""
W26 Promo Performance Tests
Navigates to key prod URLs and asserts that server response and DOM
processing times are within acceptable limits.
"""
> main_page.check_performance(_PERF_URLS)
tests/test_web_general.py:206:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
self = <pages.main_page.MainPage object at 0x7fecb5efc160>
urls = ['https://promo.com/login', 'https://promo.com/tools/calendar/march', 'https://promo.com/templates', 'https://promo.com/go/base-lp-no-search', 'https://promo.com/go/base-lp-with-search']
def check_performance(self, urls: list):
for url in urls:
server_avg, dom_avg = self.measure_page_performance(url)
print(f"{url}: server={server_avg}s, DOM={dom_avg}s")
> assert server_avg <= 3, f"Server response too slow for {url}: {server_avg}s"
E AssertionError: Server response too slow for https://promo.com/tools/calendar/march: 4.26s
pages/main_page.py:265: AssertionError
📸 Failure Screenshot: