test_1894308_docs_dingtalk_com.py (669B)
1 import pytest 2 3 URL = "https://alidocs.dingtalk.com/not-supported-env?goto=https%3A%2F%2Fdocs.dingtalk.com%2F" 4 5 SUPPORTED_URL = "docs.dingtalk.com" 6 UNSUPPORTED_CSS = "#not-supported-title" 7 8 9 @pytest.mark.skip_platforms("android") 10 @pytest.mark.asyncio 11 @pytest.mark.with_interventions 12 async def test_enabled(client): 13 redirect = await client.promise_navigation_begins(url=SUPPORTED_URL) 14 await client.navigate(URL) 15 assert await redirect 16 17 18 @pytest.mark.skip_platforms("android") 19 @pytest.mark.asyncio 20 @pytest.mark.without_interventions 21 async def test_disabled(client): 22 await client.navigate(URL) 23 assert client.await_css(UNSUPPORTED_CSS, is_displayed=True)