MCPcopy Create free account
hub / github.com/AdRoll/baker / getCorpus

Function getCorpus

input/inpututils/fastgzreader_test.go:14–34  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

12)
13
14func getCorpus() []byte {
15 files, err := filepath.Glob("*.go")
16 if err != nil {
17 panic(err)
18 }
19
20 var data []byte
21 for _, fn := range files {
22 body, err := os.ReadFile(fn)
23 if err != nil {
24 panic(err)
25 } else {
26 data = append(data, body...)
27 }
28 }
29
30 data = append(data, data...)
31 data = append(data, data...)
32
33 return data
34}
35
36func TestGzReader(t *testing.T) {
37 data := getCorpus()

Callers 3

TestGzReaderFunction · 0.85
BenchmarkGzipFunction · 0.85
BenchmarkFastGzipFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected