MCPcopy Create free account
hub / github.com/MiniCodeMonkey/chief / TestRenderTabWithBranch

Function TestRenderTabWithBranch

internal/tui/tabbar_test.go:10–29  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

8)
9
10func TestRenderTabWithBranch(t *testing.T) {
11 tb := &TabBar{}
12
13 entry := TabEntry{
14 Name: "auth",
15 Branch: "chief/auth",
16 LoopState: loop.LoopStateRunning,
17 Iteration: 3,
18 Total: 8,
19 Completed: 3,
20 }
21
22 result := tb.renderTab(entry, 1)
23 if !strings.Contains(result, "[chief/auth]") {
24 t.Errorf("expected tab to contain [chief/auth], got: %s", result)
25 }
26 if !strings.Contains(result, "auth") {
27 t.Errorf("expected tab to contain name 'auth', got: %s", result)
28 }
29}
30
31func TestRenderTabWithoutBranch(t *testing.T) {
32 tb := &TabBar{}

Callers

nothing calls this directly

Calls 1

renderTabMethod · 0.95

Tested by

no test coverage detected