2727 - jammy
2828 - noble
2929 - resolute
30- runs-on :
31- - ubuntu-24.04
32- - ubuntu-24.04-arm
30+ arch :
31+ - amd64
32+ - arm64
33+ include :
34+ - arch : amd64
35+ runs-on : playwright-x64-ubuntu24-64-core
36+ - arch : arm64
37+ runs-on : playwright-arm64-ubuntu24-64-core
3338 steps :
3439 - uses : actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
3540 - name : Set up Python
@@ -48,11 +53,20 @@ jobs:
4853 pip install -e .
4954 - name : Get Playwright
5055 run : python scripts/upstream.py checkout
56+ - name : Set up Docker
57+ run : |
58+ if ! command -v docker >/dev/null 2>&1; then
59+ curl -fsSL https://get.docker.com | sh
60+ fi
61+ sudo service docker stop
62+ sudo mkdir -p /etc/docker /mnt/docker
63+ echo '{ "data-root": "/mnt/docker" }' | sudo tee /etc/docker/daemon.json
64+ sudo service docker start
65+ # The docker group of a fresh install applies at the next login only.
66+ sudo chmod 666 /var/run/docker.sock
5167 # build.sh builds the wheels, and with them the driver.
5268 - name : Build Docker image
53- run : |
54- ARCH="${{ matrix.runs-on == 'ubuntu-24.04-arm' && 'arm64' || 'amd64' }}"
55- bash utils/docker/build.sh --$ARCH ${{ matrix.docker-image-variant }} playwright-python:localbuild-${{ matrix.docker-image-variant }}
69+ run : bash utils/docker/build.sh --${{ matrix.arch }} ${{ matrix.docker-image-variant }} playwright-python:localbuild-${{ matrix.docker-image-variant }}
5670 - name : Start the container
5771 id : container
5872 run : |
@@ -67,10 +81,10 @@ jobs:
6781 # Node.js in the image.
6882 docker exec playwright-docker-test python -m build --wheel
6983 # As in ci.yml: the dot reporter (scripts/pytest_dot_reporter.py, found through
70- # PYTHONPATH), and two workers, upstream's default of half the cores of these runners .
84+ # PYTHONPATH), and 16 workers.
7185 - name : Test Sync API
72- run : docker exec playwright-docker-test xvfb-run --auto-servernum --server-args="-screen 0 1280x960x24" pytest tests/sync -n 2 -p pytest_dot_reporter -rfE --color=yes
86+ run : docker exec playwright-docker-test xvfb-run --auto-servernum --server-args="-screen 0 1280x960x24" pytest tests/sync -n 16 -p pytest_dot_reporter -rfE --color=yes
7387 - name : Test Async API
7488 # Also after a failed sync step: the two suites report on their own.
7589 if : ${{ !cancelled() && steps.container.outcome == 'success' }}
76- run : docker exec playwright-docker-test xvfb-run --auto-servernum --server-args="-screen 0 1280x960x24" pytest tests/async -n 2 -p pytest_dot_reporter -rfE --color=yes
90+ run : docker exec playwright-docker-test xvfb-run --auto-servernum --server-args="-screen 0 1280x960x24" pytest tests/async -n 16 -p pytest_dot_reporter -rfE --color=yes
0 commit comments