Fix out of bounds access in levenshtein_editops
This commit is contained in:
parent
c41abbfe1c
commit
0362eddd18
|
@ -1 +1 @@
|
|||
Subproject commit 47df6f75a1e8c01554440017259a64f75a93a375
|
||||
Subproject commit f26ee0e935d28fe86b4fdadb357a0e642b281299
|
|
@ -55,6 +55,8 @@ def test_levenshtein_editops():
|
|||
"""
|
||||
basic test for levenshtein_editops
|
||||
"""
|
||||
assert string_metric.levenshtein_editops("0", "") == [("delete", 1, 0)]
|
||||
assert string_metric.levenshtein_editops("", "0") == [("insert", 0, 1)]
|
||||
assert string_metric.levenshtein_editops("qabxcd", "abycdf") == [
|
||||
("delete", 1, 0), ("replace", 4, 3), ("insert", 6, 6)
|
||||
]
|
||||
|
|
Loading…
Reference in New Issue