Make native GPUI checks pass on Windows

DE
1d ago
+34-30

Summary

Intent: Remove Windows-only verification failures in the standalone GPUI workspace (ANLG-320). Fixtures no longer require HOME, native paths compare by canonical identity, accepted sockets explicitly block, and the zoom test verifies Windows' intentional no-op. Unix-only CLI helper code is excluded from Windows builds.

Demo

N/A — test portability and a compile-warning fix; no user-facing behavior changes.

Verification

On Windows Server 2022, MSVC x64 and pinned Rust 1.98.1, from apps/desktop-gpui:

  • cargo fmt --check — passed.
  • cargo test --locked --workspace — passed, 496 tests; 3 existing tests ignored.
  • cargo clippy --locked --workspace --all-targets --no-deps -- -D warnings — passed.
  • cargo build --locked — passed.

Used VS DevCmd, LLVM/libclang, and a static SQLite library compiled from locked libsqlite3-sys sources. Shared-crate warnings remain outside --no-deps. License-boundary tests/check passed; repository Node script tests include pre-existing Windows/WSL failures and missing dependencies. Linux/macOS native behavior relies on GPUI CI. Real-window Windows QA is tracked separately in this session.

Link to Devin session: https://app.devin.ai/sessions/ed4624d7fe134692a31c4e82b3bbad0a
Open in Devin Desktop: https://app.devin.ai/desktop/session/ed4624d7fe134692a31c4e82b3bbad0a?variant=devin
Requested by: @ComputelessComputer


Summary by cubic

Makes the standalone GPUI workspace's tests and clippy checks pass natively on Windows.

  • Replaces HOME-dependent test fixtures with tempfile::TempDir so tests no longer require a home directory.
  • Compares path resolution results by canonical identity instead of literal strings, accommodating macOS symlinks and Windows extended-length paths.
  • Explicitly restores blocking mode on accepted sockets on Windows and spells out the intended zoom no-op in tests.
  • Gated the Unix-only temporary path helper behind cfg(unix) to fix a Windows compile warning.