MCPcopy
hub / github.com/tinylib/msgp / TestReadNil

Function TestReadNil

msgp/read_test.go:307–318  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

305}
306
307func TestReadNil(t *testing.T) {
308 var buf bytes.Buffer
309 wr := NewWriter(&buf)
310 rd := NewReader(&buf)
311
312 wr.WriteNil()
313 wr.Flush()
314 err := rd.ReadNil()
315 if err != nil {
316 t.Fatal(err)
317 }
318}
319
320func BenchmarkReadNil(b *testing.B) {
321 data := AppendNil(nil)

Callers

nothing calls this directly

Calls 5

WriteNilMethod · 0.95
FlushMethod · 0.95
ReadNilMethod · 0.95
NewWriterFunction · 0.85
NewReaderFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…