@@ -433,6 +433,10 @@ describe("widget extension signing", () => {
433433 const rust = steps . find ( step => step . name === "Setup Rust" ) ;
434434 expect ( rust ?. with ?. targets ) . toContain ( "aarch64-apple-darwin,x86_64-apple-darwin" ) ;
435435 expect ( rust ?. with ?. targets ) . toContain ( "runner.os == 'macOS'" ) ;
436+ const sidecars = steps . find ( step => step . name === "Prepare macOS sidecars" ) ;
437+ expect ( sidecars ?. run ) . toContain ( "lipo -create desktop/src-tauri/binaries/ocx-aarch64-apple-darwin" ) ;
438+ expect ( sidecars ?. run ) . toContain ( "-output desktop/src-tauri/binaries/ocx-universal-apple-darwin" ) ;
439+ expect ( sidecars ?. run ) . toContain ( "lipo -verify_arch arm64 x86_64" ) ;
436440 const prepare = steps . find ( step => step . name === "Prepare Windows installer version" ) ;
437441 expect ( prepare ?. if ) . toBe ( "runner.os == 'Windows'" ) ;
438442 expect ( prepare ?. env ?. RELEASE_VERSION ) . toBe ( "${{ inputs.version }}" ) ;
@@ -444,6 +448,18 @@ describe("widget extension signing", () => {
444448 expect ( indexOfStep ( "Prepare Windows installer version" ) ) . toBeLessThan ( indexOfStep ( "Build desktop bundles" ) ) ;
445449 } ) ;
446450
451+ test ( "Linux verifies the packaged CLI before collecting release assets" , ( ) => {
452+ const preserve = steps . find ( step => step . name === "Preserve the compiled Linux sidecar" ) ;
453+ const verify = steps . find ( step => step . name === "Verify the packaged Linux sidecar" ) ;
454+ expect ( preserve ?. if ) . toBe ( "runner.os == 'Linux'" ) ;
455+ expect ( preserve ?. run ) . toContain ( "PATCHELF=$GITHUB_WORKSPACE/desktop/scripts/appimage-patchelf.py" ) ;
456+ expect ( verify ?. if ) . toBe ( "runner.os == 'Linux'" ) ;
457+ expect ( verify ?. run ) . toBe ( "bash desktop/scripts/verify-linux-sidecar.sh" ) ;
458+ expect ( indexOfStep ( preserve ! . name ! ) ) . toBeLessThan ( indexOfStep ( "Build desktop bundles" ) ) ;
459+ expect ( indexOfStep ( verify ! . name ! ) ) . toBeGreaterThan ( indexOfStep ( "Build desktop bundles" ) ) ;
460+ expect ( indexOfStep ( verify ! . name ! ) ) . toBeLessThan ( indexOfStep ( "Rename release assets" ) ) ;
461+ } ) ;
462+
447463 test ( "the release build hands the widget a signing identity and forbids an ad-hoc fallback" , ( ) => {
448464 const build = steps . find ( step => step . name === "Build WidgetKit extension" ) ;
449465 expect ( build ) . toBeDefined ( ) ;
0 commit comments