chore: import clean Agent Desk snapshot (2/7)

This commit is contained in:
2026-10-16 11:57:21 +00:00
parent 79176541c7
commit 89c5231c4c
461 changed files with 60092 additions and 0 deletions

View File

@@ -0,0 +1,24 @@
package config
import "testing"
func TestConversationMaxOpen(t *testing.T) {
tests := []struct {
name string
config ConversationConfig
want int
}{
{name: "unset falls back to a cap", config: ConversationConfig{}, want: 3},
{name: "explicit zero also means the default", config: ConversationConfig{CustomerMaxOpen: 0}, want: 3},
{name: "explicit value wins", config: ConversationConfig{CustomerMaxOpen: 7}, want: 7},
{name: "negative removes the cap", config: ConversationConfig{CustomerMaxOpen: -1}, want: 0},
}
for _, tt := range tests {
t.Run(tt.name, func(t *testing.T) {
if got := tt.config.MaxOpen(); got != tt.want {
t.Fatalf("MaxOpen() = %d, want %d", got, tt.want)
}
})
}
}