MCPcopy
hub / github.com/uber-go/zap / FuzzSafeAppendStringLike_string

Function FuzzSafeAppendStringLike_string

zapcore/json_encoder_impl_test.go:699–717  ·  view source on GitHub ↗
(f *testing.F)

Source from the content-addressed store, hash-verified

697}
698
699func FuzzSafeAppendStringLike_string(f *testing.F) {
700 for _, s := range _stringLikeCorpus {
701 f.Add(s)
702 }
703 f.Fuzz(func(t *testing.T, s string) {
704 if !utf8.ValidString(s) {
705 t.Skip()
706 }
707
708 fuzzSafeAppendStringLike(t, s, func(buf *buffer.Buffer) {
709 safeAppendStringLike(
710 (*buffer.Buffer).AppendString,
711 utf8.DecodeRuneInString,
712 buf,
713 s,
714 )
715 })
716 })
717}
718
719func fuzzSafeAppendStringLike(
720 t *testing.T,

Callers

nothing calls this directly

Calls 3

fuzzSafeAppendStringLikeFunction · 0.85
safeAppendStringLikeFunction · 0.85
AddMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…