10
10
from .. import (
11
11
BROWSERBASE_API_KEY ,
12
12
playwright_basic ,
13
+ playwright_proxy ,
13
14
playwright_captcha ,
14
15
playwright_contexts ,
15
16
playwright_downloads ,
18
19
bb = Browserbase (api_key = BROWSERBASE_API_KEY )
19
20
load_dotenv ()
20
21
21
- SKIP_CAPTCHA_SOLVING = os .getenv ("SKIP_CAPTCHA_SOLVING " , "true " ).lower () == "true"
22
+ CI = os .getenv ("CI " , "false " ).lower () == "true"
22
23
23
24
24
25
@pytest .fixture (scope = "session" )
@@ -31,9 +32,8 @@ def test_playwright_basic(playwright: Playwright) -> None:
31
32
playwright_basic .run (playwright )
32
33
33
34
35
+ @pytest .mark .skipif (CI , reason = "Flaky and fails on CI" )
34
36
def test_playwright_captcha (playwright : Playwright ) -> None :
35
- if SKIP_CAPTCHA_SOLVING :
36
- pytest .skip ("Skipping captcha solving" )
37
37
playwright_captcha .run (playwright )
38
38
39
39
@@ -43,3 +43,31 @@ def test_playwright_contexts(playwright: Playwright) -> None:
43
43
44
44
def test_playwright_downloads (playwright : Playwright ) -> None :
45
45
playwright_downloads .run (playwright )
46
+
47
+
48
+ def test_playwright_proxy_enable_via_create_session (playwright : Playwright ) -> None :
49
+ playwright_proxy .run_enable_via_create_session (playwright )
50
+
51
+
52
+ def test_playwright_proxy_enable_via_querystring (playwright : Playwright ) -> None :
53
+ playwright_proxy .run_enable_via_querystring_with_created_session (playwright )
54
+
55
+
56
+ @pytest .mark .skipif (CI , reason = "Flaky and fails on CI" )
57
+ def test_playwright_proxy_geolocation_country (playwright : Playwright ) -> None :
58
+ playwright_proxy .run_geolocation_country (playwright )
59
+
60
+
61
+ @pytest .mark .skipif (CI , reason = "Flaky and fails on CI" )
62
+ def test_playwright_proxy_geolocation_state (playwright : Playwright ) -> None :
63
+ playwright_proxy .run_geolocation_state (playwright )
64
+
65
+
66
+ @pytest .mark .skipif (CI , reason = "Flaky and fails on CI" )
67
+ def test_playwright_proxy_geolocation_american_city (playwright : Playwright ) -> None :
68
+ playwright_proxy .run_geolocation_american_city (playwright )
69
+
70
+
71
+ @pytest .mark .skipif (CI , reason = "Flaky and fails on CI" )
72
+ def test_playwright_proxy_geolocation_non_american_city (playwright : Playwright ) -> None :
73
+ playwright_proxy .run_geolocation_non_american_city (playwright )
0 commit comments