Files
cheat/internal/config/color_test.go
Christopher Allen Lane 9b92261604 feat: migrate from docopt to cobra for CLI argument parsing
Replace docopt-go with spf13/cobra, giving cheat a built-in
`--completion` flag that dynamically generates shell completions for
bash, zsh, fish, and powershell. This replaces the manually-maintained
static completion scripts and resolves the root cause of multiple
completion issues (#768, #705, #633, #632, #476).

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
2026-02-15 18:19:20 -05:00

21 lines
340 B
Go

package config
import (
"testing"
)
// TestColor asserts that colorization rules are properly respected
func TestColor(t *testing.T) {
// mock a config
conf := Config{}
if conf.Color(false) {
t.Errorf("failed to respect forceColorize (false)")
}
if !conf.Color(true) {
t.Errorf("failed to respect forceColorize (true)")
}
}