mirror of
https://github.com/duke-git/lancet.git
synced 2026-11-16 05:12:11 +08:00
fix(strutil): validate Hamming distance by rune count (#368)
This commit is contained in:
1 parent
99ed115de4
commit
33a7e5bf6d
2 files changed
+6
-4
No files matched your search
@@ -818,6 +818,9 @@ func TestHammingDistance(t *testing.T) {
|
||||
{"abc", "def", 3},
|
||||
{"kitten", "sitting", -1},
|
||||
{"ö", "ü", 1},
|
||||
{"abc", "你", -1},
|
||||
{"你", "abc", -1},
|
||||
{"a", "你", 1},
|
||||
{"日本語", "日本語", 0},
|
||||
{"日本語", "語日本", 3},
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user