MCPcopy Create free account
hub / github.com/couchbase/sync_gateway / BenchmarkLogLevelEnabled

Function BenchmarkLogLevelEnabled

base/log_level_test.go:171–188  ·  view source on GitHub ↗
(b *testing.B)

Source from the content-addressed store, hash-verified

169}
170
171func BenchmarkLogLevelEnabled(b *testing.B) {
172 var tests = []struct {
173 Name string
174 TestLogLevel LogLevel
175 SetLogLevel LogLevel
176 }{
177 {"Hit", LevelError, LevelInfo},
178 {"Miss", LevelDebug, LevelInfo},
179 }
180
181 for _, t := range tests {
182 b.Run(t.Name, func(bn *testing.B) {
183 for i := 0; i < bn.N; i++ {
184 t.SetLogLevel.Enabled(t.TestLogLevel)
185 }
186 })
187 }
188}

Callers

nothing calls this directly

Calls 2

RunMethod · 0.65
EnabledMethod · 0.45

Tested by

no test coverage detected