(b *testing.B)
| 1587 | } |
| 1588 | |
| 1589 | func BenchmarkDiffMainRunesLargeDiffLines(b *testing.B) { |
| 1590 | fp, _ := os.Open("../testdata/diff10klinestest.txt") |
| 1591 | defer fp.Close() |
| 1592 | data, _ := ioutil.ReadAll(fp) |
| 1593 | |
| 1594 | dmp := New() |
| 1595 | |
| 1596 | b.ResetTimer() |
| 1597 | |
| 1598 | for i := 0; i < b.N; i++ { |
| 1599 | text1, text2, linearray := dmp.DiffLinesToRunes(string(data), "") |
| 1600 | |
| 1601 | diffs := dmp.DiffMainRunes(text1, text2, false) |
| 1602 | diffs = dmp.DiffCharsToLines(diffs, linearray) |
| 1603 | } |
| 1604 | } |
nothing calls this directly
no test coverage detected