MCPcopy Create free account
hub / github.com/boyter/hashit / BenchmarkProcessReadFileSingle1000Bytes

Function BenchmarkProcessReadFileSingle1000Bytes

processor/workers_test.go:133–152  ·  view source on GitHub ↗
(b *testing.B)

Source from the content-addressed store, hash-verified

131}
132
133func BenchmarkProcessReadFileSingle1000Bytes(b *testing.B) {
134 b.StopTimer()
135 Hash = append(Hash, "all")
136
137 content := ""
138 for i := 0; i < 1000; i++ {
139 content += "1"
140 }
141
142 data := []byte(content)
143 var count int64
144
145 b.StartTimer()
146
147 for i := 0; i < b.N; i++ {
148 res, _ := processReadFile("filenane", &data)
149 count += res.Bytes
150 }
151 b.Log(count)
152}

Callers

nothing calls this directly

Calls 1

processReadFileFunction · 0.85

Tested by

no test coverage detected