run_tests.yml

  1# Generated from xtask::workflows::run_tests
  2# Rebuild with `cargo xtask workflows`.
  3name: run_tests
  4env:
  5  CARGO_TERM_COLOR: always
  6  RUST_BACKTRACE: '1'
  7  CARGO_INCREMENTAL: '0'
  8on:
  9  pull_request:
 10    branches:
 11    - '**'
 12  push:
 13    branches:
 14    - main
 15    - v[0-9]+.[0-9]+.x
 16jobs:
 17  orchestrate:
 18    if: (github.repository_owner == 'zed-industries' || github.repository_owner == 'zed-extensions')
 19    runs-on: namespace-profile-2x4-ubuntu-2404
 20    steps:
 21    - name: steps::checkout_repo
 22      uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
 23      with:
 24        clean: false
 25        fetch-depth: ${{ github.ref == 'refs/heads/main' && 2 || 350 }}
 26    - id: filter
 27      name: filter
 28      run: |
 29        if [ -z "$GITHUB_BASE_REF" ]; then
 30          echo "Not in a PR context (i.e., push to main/stable/preview)"
 31          COMPARE_REV="$(git rev-parse HEAD~1)"
 32        else
 33          echo "In a PR context comparing to pull_request.base.ref"
 34          git fetch origin "$GITHUB_BASE_REF" --depth=350
 35          COMPARE_REV="$(git merge-base "origin/${GITHUB_BASE_REF}" HEAD)"
 36        fi
 37        CHANGED_FILES="$(git diff --name-only "$COMPARE_REV" ${{ github.sha }})"
 38
 39        check_pattern() {
 40          local output_name="$1"
 41          local pattern="$2"
 42          local grep_arg="$3"
 43
 44          echo "$CHANGED_FILES" | grep "$grep_arg" "$pattern" && \
 45            echo "${output_name}=true" >> "$GITHUB_OUTPUT" || \
 46            echo "${output_name}=false" >> "$GITHUB_OUTPUT"
 47        }
 48
 49        check_pattern "run_action_checks" '^\.github/(workflows/|actions/|actionlint.yml)|tooling/xtask|script/' -qP
 50        check_pattern "run_docs" '^(docs/|crates/.*\.rs)' -qP
 51        check_pattern "run_licenses" '^(Cargo.lock|script/.*licenses)' -qP
 52        check_pattern "run_nix" '^(nix/|flake\.|Cargo\.|rust-toolchain.toml|\.cargo/config.toml)' -qP
 53        check_pattern "run_tests" '^(docs/|script/update_top_ranking_issues/|\.github/(ISSUE_TEMPLATE|workflows/(?!run_tests)))' -qvP
 54    outputs:
 55      run_action_checks: ${{ steps.filter.outputs.run_action_checks }}
 56      run_docs: ${{ steps.filter.outputs.run_docs }}
 57      run_licenses: ${{ steps.filter.outputs.run_licenses }}
 58      run_nix: ${{ steps.filter.outputs.run_nix }}
 59      run_tests: ${{ steps.filter.outputs.run_tests }}
 60  check_style:
 61    if: (github.repository_owner == 'zed-industries' || github.repository_owner == 'zed-extensions')
 62    runs-on: namespace-profile-4x8-ubuntu-2204
 63    steps:
 64    - name: steps::checkout_repo
 65      uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
 66      with:
 67        clean: false
 68    - name: steps::cache_rust_dependencies_namespace
 69      uses: namespacelabs/nscloud-cache-action@v1
 70      with:
 71        cache: rust
 72        path: ~/.rustup
 73    - name: steps::setup_pnpm
 74      uses: pnpm/action-setup@fe02b34f77f8bc703788d5817da081398fad5dd2
 75      with:
 76        version: '9'
 77    - name: steps::prettier
 78      run: ./script/prettier
 79    - name: steps::cargo_fmt
 80      run: cargo fmt --all -- --check
 81    - name: ./script/check-todos
 82      run: ./script/check-todos
 83    - name: ./script/check-keymaps
 84      run: ./script/check-keymaps
 85    - name: run_tests::check_style::check_for_typos
 86      uses: crate-ci/typos@2d0ce569feab1f8752f1dde43cc2f2aa53236e06
 87      with:
 88        config: ./typos.toml
 89    timeout-minutes: 60
 90  clippy_windows:
 91    needs:
 92    - orchestrate
 93    if: needs.orchestrate.outputs.run_tests == 'true'
 94    runs-on: self-32vcpu-windows-2022
 95    steps:
 96    - name: steps::checkout_repo
 97      uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
 98      with:
 99        clean: false
100    - name: steps::setup_cargo_config
101      run: |
102        New-Item -ItemType Directory -Path "./../.cargo" -Force
103        Copy-Item -Path "./.cargo/ci-config.toml" -Destination "./../.cargo/config.toml"
104      shell: pwsh
105    - name: steps::clippy
106      run: ./script/clippy.ps1
107      shell: pwsh
108    timeout-minutes: 60
109  clippy_linux:
110    needs:
111    - orchestrate
112    if: needs.orchestrate.outputs.run_tests == 'true'
113    runs-on: namespace-profile-16x32-ubuntu-2204
114    steps:
115    - name: steps::checkout_repo
116      uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
117      with:
118        clean: false
119    - name: steps::setup_cargo_config
120      run: |
121        mkdir -p ./../.cargo
122        cp ./.cargo/ci-config.toml ./../.cargo/config.toml
123    - name: steps::cache_rust_dependencies_namespace
124      uses: namespacelabs/nscloud-cache-action@v1
125      with:
126        cache: rust
127        path: ~/.rustup
128    - name: steps::setup_linux
129      run: ./script/linux
130    - name: steps::install_mold
131      run: ./script/install-mold
132    - name: steps::download_wasi_sdk
133      run: ./script/download-wasi-sdk
134    - name: steps::clippy
135      run: ./script/clippy
136    timeout-minutes: 60
137  clippy_mac:
138    needs:
139    - orchestrate
140    if: needs.orchestrate.outputs.run_tests == 'true'
141    runs-on: namespace-profile-mac-large
142    steps:
143    - name: steps::checkout_repo
144      uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
145      with:
146        clean: false
147    - name: steps::setup_cargo_config
148      run: |
149        mkdir -p ./../.cargo
150        cp ./.cargo/ci-config.toml ./../.cargo/config.toml
151    - name: steps::cache_rust_dependencies_namespace
152      uses: namespacelabs/nscloud-cache-action@v1
153      with:
154        cache: rust
155        path: ~/.rustup
156    - name: steps::clippy
157      run: ./script/clippy
158    timeout-minutes: 60
159  run_tests_windows:
160    needs:
161    - orchestrate
162    if: needs.orchestrate.outputs.run_tests == 'true'
163    runs-on: self-32vcpu-windows-2022
164    steps:
165    - name: steps::checkout_repo
166      uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
167      with:
168        clean: false
169    - name: steps::setup_cargo_config
170      run: |
171        New-Item -ItemType Directory -Path "./../.cargo" -Force
172        Copy-Item -Path "./.cargo/ci-config.toml" -Destination "./../.cargo/config.toml"
173      shell: pwsh
174    - name: steps::setup_node
175      uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020
176      with:
177        node-version: '20'
178    - name: steps::clear_target_dir_if_large
179      run: ./script/clear-target-dir-if-larger-than.ps1 250
180      shell: pwsh
181    - name: steps::cargo_nextest
182      run: cargo nextest run --workspace --no-fail-fast
183      shell: pwsh
184    - name: steps::cleanup_cargo_config
185      if: always()
186      run: |
187        Remove-Item -Recurse -Path "./../.cargo" -Force -ErrorAction SilentlyContinue
188      shell: pwsh
189    timeout-minutes: 60
190  run_tests_linux:
191    needs:
192    - orchestrate
193    if: needs.orchestrate.outputs.run_tests == 'true'
194    runs-on: namespace-profile-16x32-ubuntu-2204
195    steps:
196    - name: steps::checkout_repo
197      uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
198      with:
199        clean: false
200    - name: steps::setup_cargo_config
201      run: |
202        mkdir -p ./../.cargo
203        cp ./.cargo/ci-config.toml ./../.cargo/config.toml
204    - name: steps::cache_rust_dependencies_namespace
205      uses: namespacelabs/nscloud-cache-action@v1
206      with:
207        cache: rust
208        path: ~/.rustup
209    - name: steps::setup_linux
210      run: ./script/linux
211    - name: steps::install_mold
212      run: ./script/install-mold
213    - name: steps::download_wasi_sdk
214      run: ./script/download-wasi-sdk
215    - name: steps::setup_node
216      uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020
217      with:
218        node-version: '20'
219    - name: steps::cargo_install_nextest
220      uses: taiki-e/install-action@nextest
221    - name: steps::clear_target_dir_if_large
222      run: ./script/clear-target-dir-if-larger-than 250
223    - name: steps::cargo_nextest
224      run: cargo nextest run --workspace --no-fail-fast
225    - name: steps::cleanup_cargo_config
226      if: always()
227      run: |
228        rm -rf ./../.cargo
229    timeout-minutes: 60
230    services:
231      postgres:
232        image: postgres:15
233        env:
234          POSTGRES_HOST_AUTH_METHOD: trust
235        ports:
236        - 5432:5432
237        options: --health-cmd pg_isready --health-interval 500ms --health-timeout 5s --health-retries 10
238  run_tests_mac:
239    needs:
240    - orchestrate
241    if: needs.orchestrate.outputs.run_tests == 'true'
242    runs-on: namespace-profile-mac-large
243    steps:
244    - name: steps::checkout_repo
245      uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
246      with:
247        clean: false
248    - name: steps::setup_cargo_config
249      run: |
250        mkdir -p ./../.cargo
251        cp ./.cargo/ci-config.toml ./../.cargo/config.toml
252    - name: steps::cache_rust_dependencies_namespace
253      uses: namespacelabs/nscloud-cache-action@v1
254      with:
255        cache: rust
256        path: ~/.rustup
257    - name: steps::setup_node
258      uses: actions/setup-node@49933ea5288caeca8642d1e84afbd3f7d6820020
259      with:
260        node-version: '20'
261    - name: steps::cargo_install_nextest
262      uses: taiki-e/install-action@nextest
263    - name: steps::clear_target_dir_if_large
264      run: ./script/clear-target-dir-if-larger-than 300
265    - name: steps::cargo_nextest
266      run: cargo nextest run --workspace --no-fail-fast
267    - name: steps::cleanup_cargo_config
268      if: always()
269      run: |
270        rm -rf ./../.cargo
271    timeout-minutes: 60
272  doctests:
273    needs:
274    - orchestrate
275    if: needs.orchestrate.outputs.run_tests == 'true'
276    runs-on: namespace-profile-16x32-ubuntu-2204
277    steps:
278    - name: steps::checkout_repo
279      uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
280      with:
281        clean: false
282    - name: steps::cache_rust_dependencies_namespace
283      uses: namespacelabs/nscloud-cache-action@v1
284      with:
285        cache: rust
286        path: ~/.rustup
287    - name: steps::setup_linux
288      run: ./script/linux
289    - name: steps::install_mold
290      run: ./script/install-mold
291    - name: steps::download_wasi_sdk
292      run: ./script/download-wasi-sdk
293    - name: steps::setup_cargo_config
294      run: |
295        mkdir -p ./../.cargo
296        cp ./.cargo/ci-config.toml ./../.cargo/config.toml
297    - id: run_doctests
298      name: run_tests::doctests::run_doctests
299      run: |
300        cargo test --workspace --doc --no-fail-fast
301    - name: steps::cleanup_cargo_config
302      if: always()
303      run: |
304        rm -rf ./../.cargo
305    timeout-minutes: 60
306  check_workspace_binaries:
307    needs:
308    - orchestrate
309    if: needs.orchestrate.outputs.run_tests == 'true'
310    runs-on: namespace-profile-8x16-ubuntu-2204
311    steps:
312    - name: steps::checkout_repo
313      uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
314      with:
315        clean: false
316    - name: steps::setup_cargo_config
317      run: |
318        mkdir -p ./../.cargo
319        cp ./.cargo/ci-config.toml ./../.cargo/config.toml
320    - name: steps::cache_rust_dependencies_namespace
321      uses: namespacelabs/nscloud-cache-action@v1
322      with:
323        cache: rust
324        path: ~/.rustup
325    - name: steps::setup_linux
326      run: ./script/linux
327    - name: steps::install_mold
328      run: ./script/install-mold
329    - name: steps::download_wasi_sdk
330      run: ./script/download-wasi-sdk
331    - name: cargo build -p collab
332      run: cargo build -p collab
333    - name: cargo build --workspace --bins --examples
334      run: cargo build --workspace --bins --examples
335    - name: steps::cleanup_cargo_config
336      if: always()
337      run: |
338        rm -rf ./../.cargo
339    timeout-minutes: 60
340  check_dependencies:
341    needs:
342    - orchestrate
343    if: needs.orchestrate.outputs.run_tests == 'true'
344    runs-on: namespace-profile-2x4-ubuntu-2404
345    steps:
346    - name: steps::checkout_repo
347      uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
348      with:
349        clean: false
350    - name: steps::cache_rust_dependencies_namespace
351      uses: namespacelabs/nscloud-cache-action@v1
352      with:
353        cache: rust
354        path: ~/.rustup
355    - name: run_tests::check_dependencies::install_cargo_machete
356      uses: clechasseur/rs-cargo@8435b10f6e71c2e3d4d3b7573003a8ce4bfc6386
357      with:
358        command: install
359        args: cargo-machete@0.7.0
360    - name: run_tests::check_dependencies::run_cargo_machete
361      uses: clechasseur/rs-cargo@8435b10f6e71c2e3d4d3b7573003a8ce4bfc6386
362      with:
363        command: machete
364    - name: run_tests::check_dependencies::check_cargo_lock
365      run: cargo update --locked --workspace
366    - name: run_tests::check_dependencies::check_vulnerable_dependencies
367      if: github.event_name == 'pull_request'
368      uses: actions/dependency-review-action@67d4f4bd7a9b17a0db54d2a7519187c65e339de8
369      with:
370        license-check: false
371    timeout-minutes: 60
372  check_docs:
373    needs:
374    - orchestrate
375    if: needs.orchestrate.outputs.run_docs == 'true'
376    runs-on: namespace-profile-8x16-ubuntu-2204
377    steps:
378    - name: steps::checkout_repo
379      uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
380      with:
381        clean: false
382    - name: steps::setup_cargo_config
383      run: |
384        mkdir -p ./../.cargo
385        cp ./.cargo/ci-config.toml ./../.cargo/config.toml
386    - name: steps::cache_rust_dependencies_namespace
387      uses: namespacelabs/nscloud-cache-action@v1
388      with:
389        cache: rust
390        path: ~/.rustup
391    - name: run_tests::check_docs::lychee_link_check
392      uses: lycheeverse/lychee-action@82202e5e9c2f4ef1a55a3d02563e1cb6041e5332
393      with:
394        args: --no-progress --exclude '^http' './docs/src/**/*'
395        fail: true
396        jobSummary: false
397    - name: steps::setup_linux
398      run: ./script/linux
399    - name: steps::install_mold
400      run: ./script/install-mold
401    - name: steps::download_wasi_sdk
402      run: ./script/download-wasi-sdk
403    - name: ./script/generate-action-metadata
404      run: ./script/generate-action-metadata
405    - name: run_tests::check_docs::install_mdbook
406      uses: peaceiris/actions-mdbook@ee69d230fe19748b7abf22df32acaa93833fad08
407      with:
408        mdbook-version: 0.4.37
409    - name: run_tests::check_docs::build_docs
410      run: |
411        mkdir -p target/deploy
412        mdbook build ./docs --dest-dir=../target/deploy/docs/
413    - name: run_tests::check_docs::lychee_link_check
414      uses: lycheeverse/lychee-action@82202e5e9c2f4ef1a55a3d02563e1cb6041e5332
415      with:
416        args: --no-progress --exclude '^http' 'target/deploy/docs'
417        fail: true
418        jobSummary: false
419    timeout-minutes: 60
420  check_licenses:
421    needs:
422    - orchestrate
423    if: needs.orchestrate.outputs.run_licenses == 'true'
424    runs-on: namespace-profile-2x4-ubuntu-2404
425    steps:
426    - name: steps::checkout_repo
427      uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
428      with:
429        clean: false
430    - name: steps::cache_rust_dependencies_namespace
431      uses: namespacelabs/nscloud-cache-action@v1
432      with:
433        cache: rust
434        path: ~/.rustup
435    - name: ./script/check-licenses
436      run: ./script/check-licenses
437    - name: ./script/generate-licenses
438      run: ./script/generate-licenses
439  check_scripts:
440    needs:
441    - orchestrate
442    if: needs.orchestrate.outputs.run_action_checks == 'true'
443    runs-on: namespace-profile-2x4-ubuntu-2404
444    steps:
445    - name: steps::checkout_repo
446      uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
447      with:
448        clean: false
449    - name: run_tests::check_scripts::run_shellcheck
450      run: ./script/shellcheck-scripts error
451    - id: get_actionlint
452      name: run_tests::check_scripts::download_actionlint
453      run: bash <(curl https://raw.githubusercontent.com/rhysd/actionlint/main/scripts/download-actionlint.bash)
454    - name: run_tests::check_scripts::run_actionlint
455      run: |
456        ${{ steps.get_actionlint.outputs.executable }} -color
457    - name: run_tests::check_scripts::check_xtask_workflows
458      run: |
459        cargo xtask workflows
460        if ! git diff --exit-code .github; then
461          echo "Error: .github directory has uncommitted changes after running 'cargo xtask workflows'"
462          echo "Please run 'cargo xtask workflows' locally and commit the changes"
463          exit 1
464        fi
465    timeout-minutes: 60
466  build_nix_linux_x86_64:
467    needs:
468    - orchestrate
469    if: needs.orchestrate.outputs.run_nix == 'true'
470    runs-on: namespace-profile-32x64-ubuntu-2004
471    env:
472      ZED_CLIENT_CHECKSUM_SEED: ${{ secrets.ZED_CLIENT_CHECKSUM_SEED }}
473      ZED_MINIDUMP_ENDPOINT: ${{ secrets.ZED_SENTRY_MINIDUMP_ENDPOINT }}
474      ZED_CLOUD_PROVIDER_ADDITIONAL_MODELS_JSON: ${{ secrets.ZED_CLOUD_PROVIDER_ADDITIONAL_MODELS_JSON }}
475      GIT_LFS_SKIP_SMUDGE: '1'
476    steps:
477    - name: steps::checkout_repo
478      uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
479      with:
480        clean: false
481    - name: steps::cache_nix_dependencies_namespace
482      uses: namespacelabs/nscloud-cache-action@v1
483      with:
484        cache: nix
485    - name: nix_build::build_nix::install_nix
486      uses: cachix/install-nix-action@02a151ada4993995686f9ed4f1be7cfbb229e56f
487      with:
488        github_access_token: ${{ secrets.GITHUB_TOKEN }}
489    - name: nix_build::build_nix::cachix_action
490      uses: cachix/cachix-action@0fc020193b5a1fa3ac4575aa3a7d3aa6a35435ad
491      with:
492        name: zed
493        authToken: ${{ secrets.CACHIX_AUTH_TOKEN }}
494        cachixArgs: -v
495        pushFilter: -zed-editor-[0-9.]*-nightly
496    - name: nix_build::build_nix::build
497      run: nix build .#debug -L --accept-flake-config
498    timeout-minutes: 60
499    continue-on-error: true
500  build_nix_mac_aarch64:
501    needs:
502    - orchestrate
503    if: needs.orchestrate.outputs.run_nix == 'true'
504    runs-on: namespace-profile-mac-large
505    env:
506      ZED_CLIENT_CHECKSUM_SEED: ${{ secrets.ZED_CLIENT_CHECKSUM_SEED }}
507      ZED_MINIDUMP_ENDPOINT: ${{ secrets.ZED_SENTRY_MINIDUMP_ENDPOINT }}
508      ZED_CLOUD_PROVIDER_ADDITIONAL_MODELS_JSON: ${{ secrets.ZED_CLOUD_PROVIDER_ADDITIONAL_MODELS_JSON }}
509      GIT_LFS_SKIP_SMUDGE: '1'
510    steps:
511    - name: steps::checkout_repo
512      uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
513      with:
514        clean: false
515    - name: steps::cache_nix_store_macos
516      uses: namespacelabs/nscloud-cache-action@v1
517      with:
518        path: ~/nix-cache
519    - name: nix_build::build_nix::install_nix
520      uses: cachix/install-nix-action@02a151ada4993995686f9ed4f1be7cfbb229e56f
521      with:
522        github_access_token: ${{ secrets.GITHUB_TOKEN }}
523    - name: nix_build::build_nix::configure_local_nix_cache
524      run: |
525        mkdir -p ~/nix-cache
526        echo "extra-substituters = file://$HOME/nix-cache?priority=10" | sudo tee -a /etc/nix/nix.conf
527        echo "require-sigs = false" | sudo tee -a /etc/nix/nix.conf
528        sudo launchctl kickstart -k system/org.nixos.nix-daemon
529    - name: nix_build::build_nix::cachix_action
530      uses: cachix/cachix-action@0fc020193b5a1fa3ac4575aa3a7d3aa6a35435ad
531      with:
532        name: zed
533        authToken: ${{ secrets.CACHIX_AUTH_TOKEN }}
534        cachixArgs: -v
535        pushFilter: -zed-editor-[0-9.]*-nightly
536    - name: nix_build::build_nix::build
537      run: nix build .#debug -L --accept-flake-config
538    - name: nix_build::build_nix::export_to_local_nix_cache
539      if: always()
540      run: |
541        if [ -L result ]; then
542          echo "Copying build closure to local binary cache..."
543          nix copy --to "file://$HOME/nix-cache" ./result || echo "Warning: nix copy to local cache failed"
544        else
545          echo "No build result found, skipping cache export."
546        fi
547    timeout-minutes: 60
548    continue-on-error: true
549  check_postgres_and_protobuf_migrations:
550    needs:
551    - orchestrate
552    if: needs.orchestrate.outputs.run_tests == 'true'
553    runs-on: namespace-profile-16x32-ubuntu-2204
554    env:
555      GIT_AUTHOR_NAME: Protobuf Action
556      GIT_AUTHOR_EMAIL: ci@zed.dev
557      GIT_COMMITTER_NAME: Protobuf Action
558      GIT_COMMITTER_EMAIL: ci@zed.dev
559    steps:
560    - name: steps::checkout_repo
561      uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683
562      with:
563        fetch-depth: 0
564    - name: run_tests::check_postgres_and_protobuf_migrations::remove_untracked_files
565      run: git clean -df
566    - name: run_tests::check_postgres_and_protobuf_migrations::ensure_fresh_merge
567      run: |
568        if [ -z "$GITHUB_BASE_REF" ];
569        then
570          echo "BUF_BASE_BRANCH=$(git merge-base origin/main HEAD)" >> "$GITHUB_ENV"
571        else
572          git checkout -B temp
573          git merge -q "origin/$GITHUB_BASE_REF" -m "merge main into temp"
574          echo "BUF_BASE_BRANCH=$GITHUB_BASE_REF" >> "$GITHUB_ENV"
575        fi
576    - name: run_tests::check_postgres_and_protobuf_migrations::bufbuild_setup_action
577      uses: bufbuild/buf-setup-action@v1
578      with:
579        version: v1.29.0
580        github_token: ${{ secrets.GITHUB_TOKEN }}
581    - name: run_tests::check_postgres_and_protobuf_migrations::bufbuild_breaking_action
582      uses: bufbuild/buf-breaking-action@v1
583      with:
584        input: crates/proto/proto/
585        against: https://github.com/${GITHUB_REPOSITORY}.git#branch=${BUF_BASE_BRANCH},subdir=crates/proto/proto/
586    timeout-minutes: 60
587  tests_pass:
588    needs:
589    - orchestrate
590    - check_style
591    - clippy_windows
592    - clippy_linux
593    - clippy_mac
594    - run_tests_windows
595    - run_tests_linux
596    - run_tests_mac
597    - doctests
598    - check_workspace_binaries
599    - check_dependencies
600    - check_docs
601    - check_licenses
602    - check_scripts
603    - build_nix_linux_x86_64
604    - build_nix_mac_aarch64
605    if: (github.repository_owner == 'zed-industries' || github.repository_owner == 'zed-extensions') && always()
606    runs-on: namespace-profile-2x4-ubuntu-2404
607    steps:
608    - name: run_tests::tests_pass
609      run: |
610        set +x
611        EXIT_CODE=0
612
613        check_result() {
614          echo "* $1: $2"
615          if [[ "$2" != "skipped" && "$2" != "success" ]]; then EXIT_CODE=1; fi
616        }
617
618        check_result "orchestrate" "${{ needs.orchestrate.result }}"
619        check_result "check_style" "${{ needs.check_style.result }}"
620        check_result "clippy_windows" "${{ needs.clippy_windows.result }}"
621        check_result "clippy_linux" "${{ needs.clippy_linux.result }}"
622        check_result "clippy_mac" "${{ needs.clippy_mac.result }}"
623        check_result "run_tests_windows" "${{ needs.run_tests_windows.result }}"
624        check_result "run_tests_linux" "${{ needs.run_tests_linux.result }}"
625        check_result "run_tests_mac" "${{ needs.run_tests_mac.result }}"
626        check_result "doctests" "${{ needs.doctests.result }}"
627        check_result "check_workspace_binaries" "${{ needs.check_workspace_binaries.result }}"
628        check_result "check_dependencies" "${{ needs.check_dependencies.result }}"
629        check_result "check_docs" "${{ needs.check_docs.result }}"
630        check_result "check_licenses" "${{ needs.check_licenses.result }}"
631        check_result "check_scripts" "${{ needs.check_scripts.result }}"
632        check_result "build_nix_linux_x86_64" "${{ needs.build_nix_linux_x86_64.result }}"
633        check_result "build_nix_mac_aarch64" "${{ needs.build_nix_mac_aarch64.result }}"
634
635        exit $EXIT_CODE
636concurrency:
637  group: ${{ github.workflow }}-${{ github.ref_name }}-${{ github.ref_name == 'main' && github.sha || 'anysha' }}
638  cancel-in-progress: true
639defaults:
640  run:
641    shell: bash -euxo pipefail {0}