MCPcopy Create free account
hub / github.com/google/pprof / TestDefaultConfig

Function TestDefaultConfig

internal/driver/settings_test.go:108–117  ·  view source on GitHub ↗

TestDefaultConfig verifies that default config values are omitted from URL.

(t *testing.T)

Source from the content-addressed store, hash-verified

106
107// TestDefaultConfig verifies that default config values are omitted from URL.
108func TestDefaultConfig(t *testing.T) {
109 cfg := defaultConfig()
110 url, changed := cfg.makeURL(url.URL{})
111 if changed {
112 t.Error("applyConfig returned changed=true after applying default config")
113 }
114 if url.String() != "" {
115 t.Errorf("applyConfig returned %q; expecting %q", url.String(), "")
116 }
117}
118
119func TestConfigMenu(t *testing.T) {
120 // Save some test settings.

Callers

nothing calls this directly

Calls 3

defaultConfigFunction · 0.85
makeURLMethod · 0.80
StringMethod · 0.65

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…