@@ -102,7 +102,7 @@ jobs:
102102 clients :
103103 name : Client and package tests
104104 needs : changes
105- if : needs.changes.outputs.test != 'false' || needs.changes.outputs.test_web != 'false'
105+ if : needs.changes.outputs.test != 'false'
106106 runs-on : ubuntu-24.04
107107 timeout-minutes : 45
108108 steps :
@@ -121,9 +121,6 @@ jobs:
121121 - uses : ./.github/actions/setup-ci-deps
122122 - name : Ensure Electron
123123 run : vp run --filter @t3tools/desktop ensure:electron
124- - name : Install Chromium
125- if : needs.changes.outputs.test_web != 'false'
126- run : node apps/web/node_modules/playwright/cli.js install --with-deps --only-shell chromium
127124 - name : Test release checks
128125 run : |
129126 python3 -B .github/scripts/stage-preview-bundle.test.py
@@ -139,9 +136,35 @@ jobs:
139136 for package in $TEST_PACKAGES; do filters+=(--filter "$package"); done
140137 fi
141138 vp run --parallel --concurrency-limit 2 "${filters[@]}" test
139+
140+ # One headless Chromium running every browser test file runs out of memory on a
141+ # standard runner and closes mid-run, so the files are split across machines.
142+ web :
143+ name : Web tests ${{ matrix.shard }}
144+ needs : changes
145+ if : needs.changes.outputs.test_web != 'false'
146+ runs-on : ubuntu-24.04
147+ timeout-minutes : 30
148+ strategy :
149+ fail-fast : false
150+ matrix :
151+ shard : [1, 2, 3, 4]
152+ steps :
153+ - name : Checkout
154+ env :
155+ GIT_TERMINAL_PROMPT : " 0"
156+ run : |
157+ git init .
158+ git remote add origin "${GITHUB_SERVER_URL}/${GITHUB_REPOSITORY}.git"
159+ git fetch --no-tags --depth=2 origin "$GITHUB_SHA"
160+ git sparse-checkout set --no-cone '/*' '!/.repos/' '!/apps/mobile/modules/t3-terminal/Vendor/**/*.a'
161+ git checkout --detach FETCH_HEAD
162+ - uses : ./.github/actions/setup-apt-mirrors
163+ - uses : ./.github/actions/setup-ci-deps
164+ - name : Install Chromium
165+ run : node apps/web/node_modules/playwright/cli.js install --with-deps --only-shell chromium
142166 - name : Test web
143- if : needs.changes.outputs.test_web != 'false'
144- run : vp run --filter @t3tools/web test
167+ run : vp run --filter @t3tools/web test --shard ${{ matrix.shard }}/${{ strategy.job-total }}
145168
146169 server :
147170 name : Server tests ${{ matrix.shard }}
@@ -232,7 +255,7 @@ jobs:
232255 check :
233256 name : Fork Check
234257 if : ${{ !cancelled() && github.repository != 'pingdotgg/t3code' }}
235- needs : [changes, checks, clients, server, rust, mobile_native]
258+ needs : [changes, checks, clients, web, server, rust, mobile_native]
236259 runs-on : ubuntu-24.04
237260 timeout-minutes : 5
238261 steps :
@@ -242,7 +265,7 @@ jobs:
242265 run : |
243266 echo "$RESULTS" | jq -r 'to_entries[] | "\(.key): \(.value.result)"'
244267 echo "$RESULTS" | jq -e '.changes.outputs as $gates
245- | {clients: ["test", "test_web"], server: ["test_server"]} as $renamed
268+ | {clients: ["test"], web: [ "test_web"], server: ["test_server"]} as $renamed
246269 | all(to_entries[];
247270 .value.result == "success"
248271 or (.value.result == "skipped"
0 commit comments