tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

test_1830739_118175_casinoextreme_eu.py (793B)


      1 import pytest
      2 
      3 URL = "https://casinoextreme.eu/games"
      4 RUN_CSS = "a.playgame-demo[onclick^='playGame']"
      5 IFRAME_CSS = "#gameplay > iframe"
      6 GOOD_MSG = "GameViewModel"
      7 BAD_MSG = "UnsupportedDevice"
      8 
      9 
     10 async def check_for_message(client, message):
     11    await client.navigate(URL)
     12    client.soft_click(client.await_css(RUN_CSS))
     13    client.switch_to_frame(client.await_css(IFRAME_CSS))
     14    await (await client.promise_console_message_listener(message))
     15 
     16 
     17 @pytest.mark.only_platforms("android")
     18 @pytest.mark.asyncio
     19 @pytest.mark.with_interventions
     20 async def test_enabled(client):
     21    await check_for_message(client, GOOD_MSG)
     22 
     23 
     24 @pytest.mark.only_platforms("android")
     25 @pytest.mark.asyncio
     26 @pytest.mark.without_interventions
     27 async def test_disabled(client):
     28    await check_for_message(client, BAD_MSG)