with one click
tui-test
// Battle-test terminal UIs such as Herald via tmux and ttyd: reset states, compare visible hotkeys with actual behavior, capture ANSI/PNG evidence, run resize soaks, and verify terminal raster image previews.
// Battle-test terminal UIs such as Herald via tmux and ttyd: reset states, compare visible hotkeys with actual behavior, capture ANSI/PNG evidence, run resize soaks, and verify terminal raster image previews.
[HINT] Download the complete skill directory including SKILL.md and all related files
| name | tui-test |
| description | Battle-test terminal UIs such as Herald via tmux and ttyd: reset states, compare visible hotkeys with actual behavior, capture ANSI/PNG evidence, run resize soaks, and verify terminal raster image previews. |
| disable-model-invocation | true |
| allowed-tools | Bash Read Write Glob Grep Edit Agent TodoWrite |
| argument-hint | [app: herald | generic] [focus: full | hotkeys | resize | timeline | compose | cleanup | contacts | ai] |
Use this skill to audit terminal UIs through tmux. It is generic by default, with a ready-made Herald profile for this repo.
For any app, note these before going deep:
For Herald in this repo, use this default profile:
go build -o /tmp/herald ./main.go
tmux kill-session -t test 2>/dev/null || true
tmux new-session -d -s test -x 220 -y 50
tmux send-keys -t test '/tmp/herald -config ~/.herald/conf.yaml' Enter
sleep 10
go build -o /tmp/herald ./main.go
tmux kill-session -t test 2>/dev/null || true
tmux new-session -d -s test -x 220 -y 50
tmux send-keys -t test '/tmp/herald --demo' Enter
sleep 5
tmux send-keys -t test Escape
sleep 0.5
tmux send-keys -t test Escape
sleep 0.5
tmux send-keys -t test '1'
sleep 1
1 Timeline2 Compose3 Cleanup4 Contacts1, 2, 3, 4EscTabfclD, e, u, ctrl+s50x15, Herald should show Terminal too narrow and recover cleanly when resized larger.Use helpers like these in the shell you control:
ROOT=$(pwd)
SKILL_DIR="$ROOT/.agents/skills/tui-test"
SESSION=test
EVIDENCE_DIR="$ROOT/reports/tui-audit_$(date +%F_%H%M%S)"
mkdir -p "$EVIDENCE_DIR"
cap() {
tmux capture-pane -t "$SESSION" -p > "$EVIDENCE_DIR/$1.txt"
}
shot() {
"$SKILL_DIR/screenshot.sh" "$SESSION" "$EVIDENCE_DIR/$1.png" "${2:-1600x900}" >/dev/null
}
cap_ansi() {
tmux capture-pane -t "$SESSION" -p -e > "$EVIDENCE_DIR/$1.ansi.txt"
}
For Herald inline image previews, run the custom ttyd browser-raster probe from the repo root:
make build
PORT=7682 EVIDENCE_DIR="$ROOT/reports/ttyd-custom-image-preview_$(date +%F_%H%M%S)" \
tools/ttyd-image-harness/probe.sh
Run the stock ttyd smoke only when you need to compare against the manual ttyd frontend:
make build
TTYD_MODE=stock PORT=7683 EVIDENCE_DIR="$ROOT/reports/ttyd-stock-image-preview_$(date +%F_%H%M%S)" \
tools/ttyd-image-harness/probe.sh
Interpretation:
-W -t enableSixel=true -t rendererType=canvas shape as the manual repro, painted the color chart plus at least one large photo region.ttyd.log, and metrics JSON before blaming Herald; missing Playwright/Chrome, a broken ttyd websocket handshake, or CDN failure can make the browser page blank.Use the bundled resize helper for soak and thrash loops:
"$SKILL_DIR/scripts/resize_cycle.sh" "$SESSION" "$EVIDENCE_DIR" timeline-preview
"$SKILL_DIR/scripts/resize_cycle.sh" "$SESSION" "$EVIDENCE_DIR" timeline-preview-thrash \
"220x50,80x24,220x50,80x24,220x50,80x24,220x50,50x15,80x24,50x15,80x24,220x50"
The resize helper writes one plain-text capture per size transition. Add PNG screenshots on:
Run this loop for every tab, overlay, or risky hotkey cluster:
Tab and Shift+Tab should move focus predictably.Esc should unwind overlays in the correct order.220x50 should clear stale too narrow, clipped, or collapsed layout state.Prioritize these in this repo:
Enter preview open and Esc closeCreative Commons image sampler for terminal previews with inline images/ search open and Esc closel logsc chatTabctrl+p previewctrl+g AI panel when configuredd domain toggleDefault cycle:
220x50 -> 120x40 -> 80x24 -> 50x15 -> 80x24 -> 120x40 -> 220x50
Default thrash:
220x50 <-> 80x24 three times, then 80x24 <-> 50x15 twice, then back to 220x50
Run the full cycle at least twice for high-value states. Log the first cycle count or transition count where the UI diverges.
Write the report under reports/ with a stable name such as:
reports/TEST_REPORT_YYYY-MM-DD_<short-description>.md
Use this structure:
# TUI Audit Report — YYYY-MM-DD
## Session
- Mode: live / demo
- Binary:
- Config:
- Sizes:
- Resize cycle:
- Thrash cycle:
## Findings
1. [Severity] Title
Repro:
Expected:
Actual:
First observed on cycle:
Evidence:
## Stable Or Lower-Risk Observations
- ...
## Testability Notes
- ...
Every finding should include:
If the current app is not Herald:
The harness should stay stable even when the app changes. The app profile is the part that should be easy to swap.