MCPcopy Create free account
hub / github.com/codehamr/codehamr / TestSlashModelRejectsUnknown

Function TestSlashModelRejectsUnknown

internal/tui/tui_test.go:832–839  ·  view source on GitHub ↗

TestSlashModelRejectsUnknown: unknown name is a quiet warn, not a switch.

(t *testing.T)

Source from the content-addressed store, hash-verified

830
831// TestSlashModelRejectsUnknown: unknown name is a quiet warn, not a switch.
832func TestSlashModelRejectsUnknown(t *testing.T) {
833 m := newTestModel(t, func(http.ResponseWriter, *http.Request) {})
834 before := m.cfg.Active
835 m2, _ := m.runSlash("/models ghost")
836 if m2.(Model).cfg.Active != before {
837 t.Fatal("unknown name must not change Active")
838 }
839}
840
841func TestSlashClearResetsHistory(t *testing.T) {
842 m := newTestModel(t, func(http.ResponseWriter, *http.Request) {})

Callers

nothing calls this directly

Calls 2

newTestModelFunction · 0.85
runSlashMethod · 0.80

Tested by

no test coverage detected