agent tracker + tmux update

This commit is contained in:
David Chen 2026-03-25 12:13:26 -07:00
parent cd9c92b1c2
commit 5064629d61
68 changed files with 15041 additions and 3483 deletions

View file

@ -0,0 +1,35 @@
package main
import "testing"
func TestDetectPaletteAgentIDFromPath(t *testing.T) {
got := detectPaletteAgentIDFromPath("/Users/david/Github/instaboard/.agents/icon-pad/repo")
if got != "icon-pad" {
t.Fatalf("expected icon-pad, got %q", got)
}
}
func TestPaletteBuildActionsIncludesDestroyWhenAgentIDKnownWithoutRecord(t *testing.T) {
r := &paletteRuntime{
agentID: "icon-pad",
mainRepoRoot: "/tmp/repo",
currentPath: "/tmp/repo/.agents/icon-pad/repo",
}
actions := r.buildActions()
for _, action := range actions {
if action.Kind == paletteActionConfirmDestroy {
return
}
}
t.Fatalf("destroy action missing: %#v", actions)
}
func TestPaletteEffectiveAgentIDIgnoresLiteralAndUsesPath(t *testing.T) {
r := &paletteRuntime{
agentID: "#{q:@agent_id}",
currentPath: "/tmp/repo/.agents/icon-pad/repo",
}
if got := r.effectiveAgentID(); got != "icon-pad" {
t.Fatalf("expected icon-pad, got %q", got)
}
}