@@ -43,59 +43,59 @@ jobs:
4343 env :
4444 # The dot reporter of the test steps (scripts/pytest_dot_reporter.py).
4545 PYTHONPATH : scripts
46+ # 16 workers on the 64-core runners, as upstream runs its tests there; two on
47+ # the 3-core macOS runner, upstream's default of half the cores.
48+ WORKERS : ${{ startsWith(matrix.os, 'macos') && '2' || '16' }}
4649 strategy :
4750 fail-fast : false
4851 matrix :
49- # ubuntu-22.04, not ubuntu-latest: the 24.04 image has no WebGL for headless
50- # Firefox (CA-008, CA-009).
51- os : [ubuntu-22.04, windows-latest, macos-latest]
52- python-version : ['3.14']
52+ # Linux and Windows run on the 64-core runners of the organization, as
53+ # upstream's tests_primary.yml; macOS on the hosted runner.
54+ # 3.12 is our most used Python version (base)
55+ os : [playwright-x64-ubuntu24-64-core, playwright-x64-server2025-64-core, macos-15-xlarge]
56+ python-version : ['3.12']
5357 browser : [chromium, firefox, webkit]
54- exclude :
55- # WebKit on standard macOS-latest (currently macos-15-arm64) is unstable;
56- # upstream pins paid macos-15-xlarge for cross-browser webkit too.
57- - os : macos-latest
58- browser : webkit
5958 include :
60- - os : windows-latest
59+ - os : playwright-x64-server2025-64-core
6160 python-version : ' 3.10'
6261 browser : chromium
63- - os : macos-latest
62+ - os : macos-15-xlarge
6463 python-version : ' 3.10'
6564 browser : chromium
66- - os : ubuntu-22.04
65+ - os : playwright-x64-ubuntu24-64-core
6766 python-version : ' 3.10'
6867 browser : chromium
69- - os : macos-15-xlarge
70- python-version : ' 3.14'
71- browser : webkit
72- - os : windows-latest
68+ - os : playwright-x64-server2025-64-core
7369 python-version : ' 3.11'
7470 browser : chromium
75- - os : macos-latest
71+ - os : macos-15-xlarge
7672 python-version : ' 3.11'
7773 browser : chromium
78- - os : ubuntu-22.04
74+ - os : playwright-x64-ubuntu24-64-core
7975 python-version : ' 3.11'
8076 browser : chromium
81- - os : windows-latest
82- python-version : ' 3.12'
83- browser : chromium
84- - os : macos-latest
85- python-version : ' 3.12'
86- browser : chromium
87- - os : ubuntu-22.04
88- python-version : ' 3.12'
89- browser : chromium
90- - os : windows-latest
77+ - os : playwright-x64-server2025-64-core
9178 python-version : ' 3.13'
9279 browser : chromium
93- - os : macos-latest
80+ - os : macos-15-xlarge
9481 python-version : ' 3.13'
9582 browser : chromium
96- - os : ubuntu-22.04
83+ - os : playwright-x64-ubuntu24-64-core
9784 python-version : ' 3.13'
9885 browser : chromium
86+ - os : playwright-x64-server2025-64-core
87+ python-version : ' 3.14'
88+ browser : chromium
89+ - os : macos-15-xlarge
90+ python-version : ' 3.14'
91+ browser : chromium
92+ - os : playwright-x64-ubuntu24-64-core
93+ python-version : ' 3.14'
94+ browser : chromium
95+ # Intel macOS, once: *-large is Intel, *-xlarge is arm64, as upstream notes.
96+ - os : macos-15-large
97+ python-version : ' 3.12'
98+ browser : chromium
9999 runs-on : ${{ matrix.os }}
100100 steps :
101101 - uses : actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
@@ -119,34 +119,34 @@ jobs:
119119 - name : Test Wheel Installation
120120 run : pytest tests/test_installation.py --browser=${{ matrix.browser }}
121121 - name : Test Sync API
122- if : matrix .os != 'ubuntu-22.04 '
123- run : pytest tests/sync --browser=${{ matrix.browser }} -n auto -p pytest_dot_reporter -rfE --color=yes
122+ if : runner .os != 'Linux '
123+ run : pytest tests/sync --browser=${{ matrix.browser }} -n ${{ env.WORKERS }} -p pytest_dot_reporter -rfE --color=yes
124124 - name : Test Sync API
125- if : matrix .os == 'ubuntu-22.04 '
126- run : xvfb-run pytest tests/sync --browser=${{ matrix.browser }} -n auto -p pytest_dot_reporter -rfE --color=yes
125+ if : runner .os == 'Linux '
126+ run : xvfb-run --auto-servernum --server-args="-screen 0 1280x960x24" pytest tests/sync --browser=${{ matrix.browser }} -n ${{ env.WORKERS }} -p pytest_dot_reporter -rfE --color=yes
127127 - name : Test Async API
128128 # Also after a failed sync step: the two suites report on their own.
129- if : ${{ !cancelled() && steps.install.outcome == 'success' && matrix .os != 'ubuntu-22.04 ' }}
130- run : pytest tests/async --browser=${{ matrix.browser }} -n auto -p pytest_dot_reporter -rfE --color=yes
129+ if : ${{ !cancelled() && steps.install.outcome == 'success' && runner .os != 'Linux ' }}
130+ run : pytest tests/async --browser=${{ matrix.browser }} -n ${{ env.WORKERS }} -p pytest_dot_reporter -rfE --color=yes
131131 - name : Test Async API
132- if : ${{ !cancelled() && steps.install.outcome == 'success' && matrix .os == 'ubuntu-22.04 ' }}
133- run : xvfb-run pytest tests/async --browser=${{ matrix.browser }} -n auto -p pytest_dot_reporter -rfE --color=yes
132+ if : ${{ !cancelled() && steps.install.outcome == 'success' && runner .os == 'Linux ' }}
133+ run : xvfb-run --auto-servernum --server-args="-screen 0 1280x960x24" pytest tests/async --browser=${{ matrix.browser }} -n ${{ env.WORKERS }} -p pytest_dot_reporter -rfE --color=yes
134134
135135 test-stable :
136136 name : Stable
137- timeout-minutes : 90
137+ # The branded browsers on the 3-core macOS runner take longer than the bundled ones.
138+ timeout-minutes : 120
138139 env :
139140 # The dot reporter of the test steps (scripts/pytest_dot_reporter.py).
140141 PYTHONPATH : scripts
142+ WORKERS : ${{ startsWith(matrix.os, 'macos') && '2' || '16' }}
141143 strategy :
142144 fail-fast : false
143145 matrix :
144- os : [ubuntu-22.04, windows-latest , macos-latest ]
146+ os : [playwright-x64-ubuntu24-64-core, playwright-x64-server2025-64-core , macos-15-xlarge ]
145147 browser-channel : [chrome]
146148 include :
147- - os : windows-latest
148- browser-channel : msedge
149- - os : macos-latest
149+ - os : playwright-x64-server2025-64-core
150150 browser-channel : msedge
151151 runs-on : ${{ matrix.os }}
152152 steps :
@@ -167,18 +167,18 @@ jobs:
167167 - name : Common Tests
168168 run : pytest tests/common --browser=chromium --browser-channel=${{ matrix.browser-channel }}
169169 - name : Test Sync API
170- if : matrix .os != 'ubuntu-22.04 '
171- run : pytest tests/sync --browser=chromium --browser-channel=${{ matrix.browser-channel }} -n auto -p pytest_dot_reporter -rfE --color=yes
170+ if : runner .os != 'Linux '
171+ run : pytest tests/sync --browser=chromium --browser-channel=${{ matrix.browser-channel }} -n ${{ env.WORKERS }} -p pytest_dot_reporter -rfE --color=yes
172172 - name : Test Sync API
173- if : matrix .os == 'ubuntu-22.04 '
174- run : xvfb-run pytest tests/sync --browser=chromium --browser-channel=${{ matrix.browser-channel }} -n auto -p pytest_dot_reporter -rfE --color=yes
173+ if : runner .os == 'Linux '
174+ run : xvfb-run --auto-servernum --server-args="-screen 0 1280x960x24" pytest tests/sync --browser=chromium --browser-channel=${{ matrix.browser-channel }} -n ${{ env.WORKERS }} -p pytest_dot_reporter -rfE --color=yes
175175 - name : Test Async API
176176 # Also after a failed sync step: the two suites report on their own.
177- if : ${{ !cancelled() && steps.install.outcome == 'success' && matrix .os != 'ubuntu-22.04 ' }}
178- run : pytest tests/async --browser=chromium --browser-channel=${{ matrix.browser-channel }} -n auto -p pytest_dot_reporter -rfE --color=yes
177+ if : ${{ !cancelled() && steps.install.outcome == 'success' && runner .os != 'Linux ' }}
178+ run : pytest tests/async --browser=chromium --browser-channel=${{ matrix.browser-channel }} -n ${{ env.WORKERS }} -p pytest_dot_reporter -rfE --color=yes
179179 - name : Test Async API
180- if : ${{ !cancelled() && steps.install.outcome == 'success' && matrix .os == 'ubuntu-22.04 ' }}
181- run : xvfb-run pytest tests/async --browser=chromium --browser-channel=${{ matrix.browser-channel }} -n auto -p pytest_dot_reporter -rfE --color=yes
180+ if : ${{ !cancelled() && steps.install.outcome == 'success' && runner .os == 'Linux ' }}
181+ run : xvfb-run --auto-servernum --server-args="-screen 0 1280x960x24" pytest tests/async --browser=chromium --browser-channel=${{ matrix.browser-channel }} -n ${{ env.WORKERS }} -p pytest_dot_reporter -rfE --color=yes
182182
183183 test_examples :
184184 name : Examples
0 commit comments