|
24 | 24 | rust: ${{ steps.filter.outputs.rust }} |
25 | 25 | gpui: ${{ steps.filter.outputs.rust == 'true' || steps.filter.outputs.gpui == 'true' || steps.desktop-resources.outputs.desktop-resources == 'true' }} |
26 | 26 | tauri-plugins: ${{ steps.filter.outputs.tauri-plugins }} |
| 27 | + gpui-patches: ${{ steps.filter.outputs.gpui-patches }} |
27 | 28 | steps: |
28 | 29 | - name: Checkout |
29 | 30 | uses: actions/checkout@v4 |
|
42 | 43 | - 'crates/**' |
43 | 44 | - 'vendor/**' |
44 | 45 | - 'scripts/diagnostic-build.rs' |
45 | | - - 'scripts/setup.js' |
| 46 | + - 'scripts/setup*' |
46 | 47 | - 'Cargo.toml' |
47 | 48 | - 'Cargo.lock' |
48 | 49 | gpui: |
|
65 | 66 | - 'scripts/sync-desktop-versions.mjs' |
66 | 67 | - 'scripts/verify-gpui-release-inputs.mjs' |
67 | 68 | - 'scripts/verify-windows-stack.mjs' |
| 69 | + gpui-patches: |
| 70 | + - 'apps/desktop-gpui/patches/**' |
| 71 | + - 'scripts/prepare-gpui-dependency.sh' |
68 | 72 | tauri-plugins: |
69 | 73 | - 'Cargo.lock' |
70 | 74 | - 'bun.lock' |
@@ -123,6 +127,7 @@ jobs: |
123 | 127 | __tests__/unit/linkified-text.test.ts |
124 | 128 | __tests__/unit/loom-import-ui.test.ts |
125 | 129 | __tests__/unit/media-player-store-refs.test.ts |
| 130 | + __tests__/unit/playback-store.test.ts |
126 | 131 | __tests__/unit/seo-demo-videos.test.ts |
127 | 132 | __tests__/unit/signed-baa-card.test.ts |
128 | 133 | __tests__/unit/summary-editor.test.ts |
@@ -273,6 +278,9 @@ jobs: |
273 | 278 | prefix-key: v1-rust-tests |
274 | 279 | save-cache: ${{ github.ref == 'refs/heads/main' }} |
275 | 280 |
|
| 281 | + - name: Test native dependency setup |
| 282 | + run: node --test scripts/setup.test.mjs |
| 283 | + |
276 | 284 | - name: Run setup |
277 | 285 | run: node scripts/setup.js |
278 | 286 |
|
@@ -370,6 +378,70 @@ jobs: |
370 | 378 | fi |
371 | 379 | cargo +1.95.0 test --manifest-path apps/desktop-gpui/Cargo.toml --locked --target ${{ matrix.settings.target }} -p cap-gpui-kernels |
372 | 380 |
|
| 381 | + # Cap only builds gpui's crates as dependencies, so their own tests never run |
| 382 | + # in the app jobs above. Run the ones covering Cap's patches against real |
| 383 | + # devices: Metal on macOS, WARP on Windows, and Mesa's lavapipe (Vulkan) and |
| 384 | + # llvmpipe (GL) on Linux. Windows renders with D3D11 and its runners expose |
| 385 | + # no wgpu adapter, so wgpu's tests run on macOS and Linux only. Zed's lockfile predates the patches' dependency |
| 386 | + # changes, so these builds cannot use --locked. |
| 387 | + gpui-patch-tests: |
| 388 | + name: GPUI patch tests (${{ matrix.settings.name }}) |
| 389 | + needs: changes |
| 390 | + if: needs.changes.outputs.gpui-patches == 'true' |
| 391 | + timeout-minutes: 90 |
| 392 | + strategy: |
| 393 | + fail-fast: false |
| 394 | + matrix: |
| 395 | + settings: |
| 396 | + - name: macOS |
| 397 | + runner: blacksmith-6vcpu-macos-15 |
| 398 | + - name: Windows |
| 399 | + runner: blacksmith-8vcpu-windows-2025 |
| 400 | + - name: Linux |
| 401 | + runner: blacksmith-8vcpu-ubuntu-2404 |
| 402 | + runs-on: ${{ matrix.settings.runner }} |
| 403 | + env: |
| 404 | + CARGO_PROFILE_DEV_DEBUG: "0" |
| 405 | + steps: |
| 406 | + - name: Checkout repository |
| 407 | + uses: actions/checkout@v4 |
| 408 | + |
| 409 | + - name: Install Linux desktop dependencies |
| 410 | + if: ${{ runner.os == 'Linux' }} |
| 411 | + uses: ./.github/actions/install-desktop-deps |
| 412 | + |
| 413 | + - name: Install software GPU drivers |
| 414 | + if: ${{ runner.os == 'Linux' }} |
| 415 | + run: sudo apt-get install -y --no-install-recommends mesa-vulkan-drivers libvulkan1 libegl1 libegl-mesa0 libgl1-mesa-dri |
| 416 | + |
| 417 | + - name: Allow long paths in Zed's git dependencies |
| 418 | + if: ${{ runner.os == 'Windows' }} |
| 419 | + run: git config --global core.longpaths true |
| 420 | + |
| 421 | + - name: Rust setup |
| 422 | + uses: dtolnay/rust-toolchain@1.95.0 |
| 423 | + |
| 424 | + - name: Prepare GPUI dependency |
| 425 | + shell: bash |
| 426 | + run: ./scripts/prepare-gpui-dependency.sh |
| 427 | + |
| 428 | + - name: Test GPUI patches |
| 429 | + shell: bash |
| 430 | + working-directory: ../zed-cap |
| 431 | + env: |
| 432 | + GPUI_REQUIRE_TEST_DEVICE: "1" |
| 433 | + run: | |
| 434 | + cargo +1.95.0 test -p gpui --lib stream |
| 435 | + if [[ "$RUNNER_OS" == "Linux" ]]; then |
| 436 | + WGPU_BACKEND=vulkan cargo +1.95.0 test -p gpui_wgpu --lib wgpu_atlas -- --nocapture |
| 437 | + WGPU_BACKEND=gl cargo +1.95.0 test -p gpui_wgpu --lib wgpu_atlas -- --nocapture |
| 438 | + elif [[ "$RUNNER_OS" == "macOS" ]]; then |
| 439 | + cargo +1.95.0 test -p gpui_wgpu --lib wgpu_atlas -- --nocapture |
| 440 | + cargo +1.95.0 test -p gpui_macos --lib -- metal_atlas metal_renderer |
| 441 | + else |
| 442 | + cargo +1.95.0 test -p gpui_windows --lib directx_atlas |
| 443 | + fi |
| 444 | +
|
373 | 445 | tauri-plugins: |
374 | 446 | name: Verify Tauri plugin versions |
375 | 447 | runs-on: blacksmith-8vcpu-ubuntu-2404 |
|
0 commit comments