Add bundled Ghostty helper regression test

This commit is contained in:
Lawrence Chen 2026-03-14 22:30:01 -07:00
parent 6c203b5144
commit 2167323153
No known key found for this signature in database
2 changed files with 48 additions and 0 deletions

View file

@ -154,6 +154,12 @@ jobs:
fi
fi
- name: Run bundled Ghostty theme picker helper regression
run: |
set -euo pipefail
CMUX_SOURCE_PACKAGES_DIR="$PWD/.ci-source-packages" \
./tests/test_bundled_ghostty_theme_picker_helper.sh
- name: Run CLI version memory guard regression
run: |
set -euo pipefail

View file

@ -0,0 +1,42 @@
#!/usr/bin/env bash
set -euo pipefail
SOURCE_PACKAGES_DIR="${CMUX_SOURCE_PACKAGES_DIR:-$PWD/.ci-source-packages}"
DERIVED_DATA_PATH="${CMUX_DERIVED_DATA_PATH:-$PWD/.ci-bundled-ghostty-helper}"
CONFIGURATION="${CMUX_CONFIGURATION:-Debug}"
case "$CONFIGURATION" in
Debug)
APP_NAME="cmux DEV.app"
;;
Release)
APP_NAME="cmux.app"
;;
*)
echo "FAIL: unsupported configuration $CONFIGURATION" >&2
exit 1
;;
esac
mkdir -p "$SOURCE_PACKAGES_DIR"
rm -rf "$DERIVED_DATA_PATH"
xcodebuild \
-project GhosttyTabs.xcodeproj \
-scheme cmux \
-configuration "$CONFIGURATION" \
-clonedSourcePackagesDirPath "$SOURCE_PACKAGES_DIR" \
-disableAutomaticPackageResolution \
-derivedDataPath "$DERIVED_DATA_PATH" \
-destination "platform=macOS" \
build
APP_PATH="$DERIVED_DATA_PATH/Build/Products/$CONFIGURATION/$APP_NAME"
HELPER_PATH="$APP_PATH/Contents/Resources/bin/ghostty"
if [ ! -x "$HELPER_PATH" ]; then
echo "FAIL: bundled Ghostty theme picker helper missing at $HELPER_PATH" >&2
exit 1
fi
echo "PASS: bundled Ghostty theme picker helper present at $HELPER_PATH"