Studio: run the src-tauri unit tests in CI and fix the two that never ran (#7558)
studio-tauri-smoke.yml only ever built the crate, so none of its ~100 unit tests executed. Running them surfaced two that were broken on platforms CI never exercised: - non_utf8_import_name_preserves_csv_extension built a filename containing a raw 0xFF byte. Linux stores that fine, macOS enforces UTF-8 on APFS/HFS+ and refuses to create it, so the test panicked on the unwrap. Skip when the filesystem rejects the name; the branch under test is only reachable where such a file can exist. - losing_a_studio_package_changes_the_fingerprint created the posix venv layout unconditionally, but site_packages_dirs() only walks lib/<pyver>/site-packages on unix and looks at Lib/site-packages on Windows. The dist-info was therefore invisible to the fingerprint there, removing it changed nothing and the assert_ne could never hold. Build the layout the code actually reads for the target platform. Add the cargo test step to the existing Tauri job, where the toolchain and WebKit dev packages are already installed.
This commit is contained in:
parent
9e568c14e6
commit
71f7e1087b
3 changed files with 26 additions and 2 deletions
10
.github/workflows/studio-tauri-smoke.yml
vendored
10
.github/workflows/studio-tauri-smoke.yml
vendored
|
|
@ -91,6 +91,16 @@ jobs:
|
|||
npm run build
|
||||
test -f dist/index.html
|
||||
|
||||
# The crate carries ~100 unit tests (native_file_dialogs, preflight,
|
||||
# install, desktop_auth, ...) that nothing ran until now: this workflow
|
||||
# only ever built. Run them here, where the toolchain and the WebKit dev
|
||||
# packages are already installed, so a broken assertion fails the PR
|
||||
# instead of sitting unnoticed. `--no-fail-fast` reports every failing
|
||||
# test in one run rather than stopping at the first.
|
||||
- name: Rust unit tests (studio/src-tauri)
|
||||
working-directory: studio/src-tauri
|
||||
run: cargo test --no-fail-fast
|
||||
|
||||
- name: Tauri debug build (Linux, no bundle, no codesign)
|
||||
# `--debug` + `--no-bundle` keeps this lean: compiles the Rust crate,
|
||||
# confirms the frontend dist is wired into Tauri, but skips the AppImage
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue