MCPcopy Create free account
hub / github.com/sergi/go-diff / BenchmarkDiffHalfMatch

Function BenchmarkDiffHalfMatch

diffmatchpatch/diff_test.go:270–280  ·  view source on GitHub ↗
(b *testing.B)

Source from the content-addressed store, hash-verified

268}
269
270func BenchmarkDiffHalfMatch(b *testing.B) {
271 s1, s2 := speedtestTexts()
272
273 dmp := New()
274
275 b.ResetTimer()
276
277 for i := 0; i < b.N; i++ {
278 dmp.DiffHalfMatch(s1, s2)
279 }
280}
281
282func TestDiffBisectSplit(t *testing.T) {
283 type TestCase struct {

Callers

nothing calls this directly

Calls 3

speedtestTextsFunction · 0.85
NewFunction · 0.85
DiffHalfMatchMethod · 0.80

Tested by

no test coverage detected