MCPcopy Create free account
hub / github.com/Facets-cloud/flow / TestFocusSessionEmptyID

Function TestFocusSessionEmptyID

internal/kitty/kitty_test.go:163–176  ·  view source on GitHub ↗

TestFocusSessionEmptyID short-circuits without invoking kitty.

(t *testing.T)

Source from the content-addressed store, hash-verified

161
162// TestFocusSessionEmptyID short-circuits without invoking kitty.
163func TestFocusSessionEmptyID(t *testing.T) {
164 rCalled := false
165 stubRunnerOutput(t, func(args []string) ([]byte, error) {
166 rCalled = true
167 return nil, nil
168 })
169 focused, err := FocusSession("", "claude")
170 if focused || err != nil {
171 t.Errorf("FocusSession(\"\") = (%v, %v); want (false, nil)", focused, err)
172 }
173 if rCalled {
174 t.Error("RunnerOutput should not be called for empty session id")
175 }
176}
177
178// TestFocusSessionMatchesAndFocuses verifies the happy path: a
179// foreground process under a kitty window runs claude with the target

Callers

nothing calls this directly

Calls 3

ErrorMethod · 0.80
stubRunnerOutputFunction · 0.70
FocusSessionFunction · 0.70

Tested by

no test coverage detected