fix(macos): bundle the CLI and resolve it from generated droplets

This commit is contained in:
Nigel Ihza Firdausy committed 2026-10-13 11:02:07 +07:00
1 parent 8a6ce79c6f
commit fd72eafc48
1 file changed
+2
+2
View File
@@ -135,6 +135,8 @@ fn droplets_are_written_and_run() {
let shim = r["shim"].as_str().unwrap();
let text = std::fs::read_to_string(shim).unwrap();
assert!(text.starts_with("#!/bin/sh") && text.contains("droplet"));
assert!(text.contains("/Applications/PhotoCraft.app/Contents/MacOS/photocraft-cli"));
assert!(text.contains("${PHOTOCRAFT_CLI:-}"), "an explicit CLI path must take priority");
use std::os::unix::fs::PermissionsExt;
assert_ne!(std::fs::metadata(shim).unwrap().permissions().mode() & 0o111, 0, "executable");
}