mirror of
https://github.com/kovidgoyal/kitty
synced 2026-07-25 09:48:09 +02:00
Port calls to slices.Sort functions since they now need a cmp() function rather than a less() function
Also rename os.SEEK_* to io.Seek* as the former has been deprecated
This commit is contained in:
@@ -18,9 +18,9 @@ func TestUnicodeInputQueries(t *testing.T) {
|
||||
if expected == nil {
|
||||
expected = make([]rune, 0)
|
||||
}
|
||||
expected = utils.Sort(expected, func(a, b rune) bool { return a < b })
|
||||
expected = utils.Sort(expected, func(a, b rune) int { return int(a) - int(b) })
|
||||
actual := CodePointsForQuery(query)
|
||||
actual = utils.Sort(actual, func(a, b rune) bool { return a < b })
|
||||
actual = utils.Sort(actual, func(a, b rune) int { return int(a) - int(b) })
|
||||
diff := cmp.Diff(expected, actual)
|
||||
if diff != "" {
|
||||
t.Fatalf("Failed query: %#v\n%s", query, diff)
|
||||
|
||||
Reference in New Issue
Block a user