@@ -218,7 +218,10 @@ jobs:
218218 fail-fast : false
219219 matrix :
220220 include :
221- - node-version : 22
221+ - node-version : 24.15.0
222+ test-filter : " **"
223+ filter-label : " **"
224+ - node-version : 20.19.0
222225 test-filter : " **"
223226 filter-label : " **"
224227
@@ -257,7 +260,7 @@ jobs:
257260 - name : Run Typedoc tests
258261 run : |
259262 # Only run Typedoc tests for one matrix version and main test run
260- if [ "${{ matrix.node-version }}" == "22 " ] && [ "${{ matrix.test-filter }}" = "**" ]; then
263+ if [ "${{ matrix.node-version }}" == "24.15.0 " ] && [ "${{ matrix.test-filter }}" = "**" ]; then
261264 pnpm turbo run //#test:typedoc
262265 fi
263266 env :
@@ -274,7 +277,9 @@ jobs:
274277
275278 integration-tests :
276279 needs : [check-permissions, build-packages]
277- if : ${{ github.event_name != 'pull_request' || github.event.pull_request.draft == false }}
280+ if : >-
281+ ${{ (github.event_name != 'pull_request' || github.event.pull_request.draft == false)
282+ && (github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name == github.repository) }}
278283 name : Integration Tests (${{ matrix.test-name }}, ${{ matrix.test-project }}${{ matrix.next-version && format(', {0}', matrix.next-version) || '' }})
279284 permissions :
280285 contents : read
@@ -292,6 +297,7 @@ jobs:
292297 [
293298 " generic" ,
294299 " express" ,
300+ " fastify" ,
295301 " ap-flows" ,
296302 " localhost" ,
297303 " sessions" ,
@@ -305,6 +311,7 @@ jobs:
305311 " react-router" ,
306312 " custom" ,
307313 " hono" ,
314+ " chrome-extension" ,
308315 ]
309316 test-project : ["chrome"]
310317 include :
@@ -355,8 +362,7 @@ jobs:
355362 fi
356363 jq --version
357364
358- - name : Task Status
359- id : task-status
365+ - name : Validate turbo task
360366 env :
361367 E2E_APP_CLERK_JS_DIR : ${{runner.temp}}
362368 E2E_APP_CLERK_UI_DIR : ${{runner.temp}}
@@ -366,40 +372,48 @@ jobs:
366372 E2E_PROJECT : ${{ matrix.test-project }}
367373 INTEGRATION_INSTANCE_KEYS : ${{ secrets.INTEGRATION_INSTANCE_KEYS }}
368374 run : |
369- # Use turbo's built-in --affected flag to detect changes
370- # This automatically uses GITHUB_BASE_REF in GitHub Actions
371- TASK_COUNT=$(pnpm turbo run test:integration:${{ matrix.test-name }} --affected --dry=json 2>/dev/null | jq '.tasks | length' 2>/dev/null || echo "0")
375+ # Validate the turbo task exists. Turbo's --affected flag is a no-op for
376+ # root-level tasks (//#) — they are always returned as affected. The previous
377+ # --affected check only served to silently skip tests when the task was missing
378+ # from turbo.json, hiding real configuration errors.
379+ TASK_NAME="test:integration:${{ matrix.test-name }}"
380+ TURBO_STDERR=$(mktemp)
381+ if ! TURBO_JSON=$(pnpm turbo run "$TASK_NAME" --dry=json 2>"$TURBO_STDERR"); then
382+ echo "::error::Turbo task '$TASK_NAME' failed validation"
383+ cat "$TURBO_STDERR"
384+ exit 1
385+ fi
372386
373- if [ "$ TASK_COUNT" -gt 0 ] ; then
374- AFFECTED=1
375- else
376- AFFECTED=0
387+ if ! TASK_COUNT=$(jq -er '.tasks | length' <<< "$TURBO_JSON") ; then
388+ echo "::error::Turbo task '$TASK_NAME' returned invalid JSON or missing .tasks"
389+ printf '%s\n' "$TURBO_JSON"
390+ exit 1
377391 fi
378392
379- echo "affected=${AFFECTED}"
380- echo "affected=${AFFECTED}" >> $GITHUB_OUTPUT
393+ if [ "$TASK_COUNT" -eq 0 ]; then
394+ echo "::error::Turbo task '$TASK_NAME' returned 0 tasks"
395+ exit 1
396+ fi
397+
398+ echo "Task '$TASK_NAME' validated ($TASK_COUNT tasks in graph)"
381399
382400 - name : Build packages
383- if : ${{ steps.task-status.outputs.affected == '1' }}
384401 run : pnpm turbo build $TURBO_ARGS --only
385402
386403 - name : Publish to local registry
387- if : ${{ steps.task-status.outputs.affected == '1' }}
388404 run : pkglab pub --force
389405
390406 - name : Edit .npmrc [link-workspace-packages=false]
391407 run : sed -i -E 's/link-workspace-packages=(deep|true)/link-workspace-packages=false/' .npmrc
392408
393409 - name : Install @clerk/clerk-js in os temp
394- if : ${{ steps.task-status.outputs.affected == '1' }}
395410 working-directory : ${{runner.temp}}
396411 run : |
397412 mkdir clerk-js && cd clerk-js
398413 pnpm init
399414 pkglab add @clerk/clerk-js
400415
401416 - name : Install @clerk/ui in os temp
402- if : ${{ steps.task-status.outputs.affected == '1' }}
403417 working-directory : ${{runner.temp}}
404418 run : |
405419 mkdir clerk-ui && cd clerk-ui
@@ -411,7 +425,6 @@ jobs:
411425 run : cd packages/astro && pnpm copy:components
412426
413427 - name : Write all ENV certificates to files in integration/certs
414- if : ${{ steps.task-status.outputs.affected == '1' }}
415428 uses : actions/github-script@v7
416429 env :
417430 INTEGRATION_CERTS : " ${{secrets.INTEGRATION_CERTS}}"
@@ -429,12 +442,10 @@ jobs:
429442 }
430443
431444 - name : LS certs
432- if : ${{ steps.task-status.outputs.affected == '1' }}
433445 working-directory : ./integration/certs
434446 run : ls -la && pwd
435447
436448 - name : Run Integration Tests
437- if : ${{ steps.task-status.outputs.affected == '1' }}
438449 id : integration-tests
439450 timeout-minutes : 25
440451 run : pnpm turbo test:integration:${{ matrix.test-name }} $TURBO_ARGS
@@ -451,12 +462,21 @@ jobs:
451462 NODE_EXTRA_CA_CERTS : ${{ github.workspace }}/integration/certs/rootCA.pem
452463 VERCEL_AUTOMATION_BYPASS_SECRET : ${{ secrets.VERCEL_AUTOMATION_BYPASS_SECRET }}
453464
465+ - name : Sanitize artifact name
466+ if : ${{ cancelled() || failure() }}
467+ id : sanitize
468+ run : |
469+ SANITIZED="${TEST_NAME//:/-}"
470+ echo "artifact-suffix=${SANITIZED}" >> $GITHUB_OUTPUT
471+ env :
472+ TEST_NAME : ${{ matrix.test-name }}
473+
454474 - name : Upload test-results
455475 if : ${{ cancelled() || failure() }}
456476 uses : actions/upload-artifact@v4
457477 with :
458- name : playwright-traces-${{ github.run_id }}-${{ github.run_attempt }}-${{ matrix.test-name }}${{ matrix.next-version && format('-next{0}', matrix.next-version) || '' }}
459- path : integration/ test-results
478+ name : playwright-traces-${{ github.run_id }}-${{ github.run_attempt }}-${{ steps.sanitize.outputs.artifact-suffix }}${{ matrix.next-version && format('-next{0}', matrix.next-version) || '' }}
479+ path : test-results
460480 retention-days : 1
461481
462482 pkg-pr-new :
@@ -484,7 +504,7 @@ jobs:
484504 uses : ./.github/actions/init-blacksmith
485505 with :
486506 turbo-enabled : true
487- node-version : 22
507+ node-version : 24.15.0
488508 turbo-signature : ${{ secrets.TURBO_REMOTE_CACHE_SIGNATURE_KEY }}
489509 turbo-summarize : ${{ env.TURBO_SUMMARIZE }}
490510 turbo-team : ${{ vars.TURBO_TEAM }}
0 commit comments