Tests for hooks time and count.

This commit is contained in:
Nicholas Marriott
2026-07-28 08:08:26 +01:00
parent e2a5ea2e78
commit 3c1b2969a8
2 changed files with 10 additions and 0 deletions

View File

@@ -81,6 +81,11 @@ assert_unchanged @seen 0
$TMUX rename-session two || fail "rename-session two failed"
wait_for @seen '@session-name:two'
shown=$($TMUX show-hooks -g -BF '#{hook_fire_count}:#{t/p:hook_fire_time}' \
@session-name) ||
fail "show-hooks -BF fire failed"
echo "$shown" | grep -q '^1:[^-][^ ]*$' ||
fail "unexpected show-hooks -BF fire output: $shown"
$TMUX set -g @seen-last 0 || fail "set @seen-last failed"
$TMUX set-hook -g -B '@session-name::#{session_name}' \