MCPcopy Create free account
hub / github.com/0x676e67/wreq-python / test_update_impersonate

Function test_update_impersonate

tests/client_test.py:64–80  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

62@pytest.mark.asyncio
63@pytest.mark.flaky(reruns=3, reruns_delay=2)
64async def test_update_impersonate():
65 client = rnet.Client(impersonate=Impersonate.Firefox133)
66 assert (
67 client.user_agent
68 == "Mozilla/5.0 (Macintosh; Intel Mac OS X 10.15; rv:133.0) Gecko/20100101 Firefox/133.0"
69 )
70 client.update(
71 impersonate=ImpersonateOption(
72 impersonate=Impersonate.Firefox135,
73 impersonate_os=ImpersonateOS.Windows,
74 skip_headers=False,
75 )
76 )
77 assert (
78 client.user_agent
79 == "Mozilla/5.0 (Windows NT 10.0; rv:135.0) Gecko/20100101 Firefox/135.0"
80 )
81
82
83@pytest.mark.asyncio

Callers

nothing calls this directly

Calls 2

updateMethod · 0.95
ImpersonateOptionClass · 0.85

Tested by

no test coverage detected