(b *testing.B)
| 174 | } |
| 175 | |
| 176 | func BenchmarkMatchBitap(b *testing.B) { |
| 177 | s1, _ := speedtestTexts() |
| 178 | // A pattern near MatchMaxBits with a few typos, searched far from its real location. |
| 179 | pattern := "Twas brilig, and the slithy tove" |
| 180 | |
| 181 | dmp := New() |
| 182 | |
| 183 | b.ResetTimer() |
| 184 | |
| 185 | for i := 0; i < b.N; i++ { |
| 186 | dmp.MatchBitap(s1, pattern, len(s1)/2) |
| 187 | } |
| 188 | } |
nothing calls this directly
no test coverage detected