MCPcopy
hub / github.com/gofiber/fiber / Test_Tracew

Function Test_Tracew

log/default_test.go:495–507  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

493}
494
495func Test_Tracew(t *testing.T) {
496 initDefaultLogger()
497
498 var w byteSliceWriter
499 SetOutput(&w)
500
501 msg := "trace work"
502 keysAndValues := []any{"key1", "value1", "key2", "value2"}
503
504 Tracew(msg, keysAndValues...)
505
506 require.Equal(t, "[Trace] trace work key1=value1 key2=value2\n", string(w.b))
507}
508
509type stringKey struct {
510 value string

Callers

nothing calls this directly

Calls 3

initDefaultLoggerFunction · 0.85
SetOutputFunction · 0.85
TracewFunction · 0.85

Tested by

no test coverage detected