MCPcopy Create free account
hub / github.com/diillson/chatcli / TestChatKnowledgeEnabled_DefaultAndOff

Function TestChatKnowledgeEnabled_DefaultAndOff

cli/chat_knowledge_test.go:17–26  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

15)
16
17func TestChatKnowledgeEnabled_DefaultAndOff(t *testing.T) {
18 t.Setenv(chatKnowledgeEnvVar, "")
19 if !chatKnowledgeEnabled() {
20 t.Error("default must be ON when unset")
21 }
22 t.Setenv(chatKnowledgeEnvVar, "off")
23 if chatKnowledgeEnabled() {
24 t.Error("off must disable")
25 }
26}
27
28func TestChatKnowledgeActive_RequiresHandlerAndAttachment(t *testing.T) {
29 t.Setenv(chatKnowledgeEnvVar, "true")

Callers

nothing calls this directly

Calls 2

chatKnowledgeEnabledFunction · 0.85
ErrorMethod · 0.65

Tested by

no test coverage detected