test_1898939_smartgpseco_com.py (624B)
1 import pytest 2 from webdriver.error import NoSuchElementException 3 4 URL = "https://www.smartgpseco.com/#sign/sign_in" 5 6 UNSUPPORTED_TEXT = "only supports Google Chrome" 7 8 9 @pytest.mark.asyncio 10 @pytest.mark.with_interventions 11 async def test_enabled(client): 12 await client.navigate(URL) 13 try: 14 client.await_text(UNSUPPORTED_TEXT, is_displayed=True, timeout=5) 15 assert False 16 except NoSuchElementException: 17 assert True 18 19 20 @pytest.mark.asyncio 21 @pytest.mark.without_interventions 22 async def test_disabled(client): 23 await client.navigate(URL) 24 client.await_text(UNSUPPORTED_TEXT, is_displayed=True)