MCPcopy
hub / github.com/cheat/cheat / TestConfigDefaults

Function TestConfigDefaults

internal/config/config_extended_test.go:34–49  ·  view source on GitHub ↗

TestConfigDefaults tests default values

(t *testing.T)

Source from the content-addressed store, hash-verified

32
33// TestConfigDefaults tests default values
34func TestConfigDefaults(t *testing.T) {
35 // Load empty config
36 conf, err := New(mocks.Path("conf/empty.yml"), false)
37 if err != nil {
38 t.Errorf("failed to load config: %v", err)
39 }
40
41 // Check defaults
42 if conf.Style != "bw" {
43 t.Errorf("expected default style 'bw', got %s", conf.Style)
44 }
45
46 if conf.Formatter != "terminal" {
47 t.Errorf("expected default formatter 'terminal', got %s", conf.Formatter)
48 }
49}
50
51// TestConfigSymlinkResolution tests symlink resolution
52func TestConfigSymlinkResolution(t *testing.T) {

Callers

nothing calls this directly

Calls 2

PathFunction · 0.92
NewFunction · 0.70

Tested by

no test coverage detected