MCPcopy Index your code
hub / github.com/cli/cli / TestFallbackConfig

Function TestFallbackConfig

internal/config/config_test.go:132–143  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

130}
131
132func TestFallbackConfig(t *testing.T) {
133 cfg := fallbackConfig()
134 requireKeyWithValue(t, cfg, []string{gitProtocolKey}, "https")
135 requireKeyWithValue(t, cfg, []string{editorKey}, "")
136 requireKeyWithValue(t, cfg, []string{promptKey}, "enabled")
137 requireKeyWithValue(t, cfg, []string{pagerKey}, "")
138 requireKeyWithValue(t, cfg, []string{aliasesKey, "co"}, "pr checkout")
139 requireKeyWithValue(t, cfg, []string{httpUnixSocketKey}, "")
140 requireKeyWithValue(t, cfg, []string{browserKey}, "")
141 requireKeyWithValue(t, cfg, []string{colorLabelsKey}, "disabled")
142 requireNoKey(t, cfg, []string{"unknown"})
143}
144
145func TestSetTopLevelKey(t *testing.T) {
146 c := newTestConfig()

Callers

nothing calls this directly

Calls 3

fallbackConfigFunction · 0.85
requireKeyWithValueFunction · 0.70
requireNoKeyFunction · 0.70

Tested by

no test coverage detected