Commit b530190
committed
Made spelling suggestion case sensitive
... and fixed a bug in the test data.
This reduced the count of failures in the Suggestion.spellingSuggestions
unit test from 8 to 1:
[ RUN ] Suggestion.spellingSuggestions
Resolve redirect
set index
test/suggestion.cpp:841: Failure
Expected equality of these values:
getSpellingSuggestions(a, "Lax", 1)
Which is: {}
std::vector<std::string> ({"Lachs"})
Which is: { "Lachs" }
[ FAILED ] Suggestion.spellingSuggestions (260 ms)
The spelling correction "Lax -> Lachs" is not returned because the max
edit distance is capped at (length(query_word) - 1) which reduces our
passed value of the max edit distance argument from 3 to 2. It is not
clear why the client's test works.1 parent 04d82ad commit b530190
2 files changed
+2
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
406 | 406 | | |
407 | 407 | | |
408 | 408 | | |
409 | | - | |
| 409 | + | |
410 | 410 | | |
411 | 411 | | |
412 | 412 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
785 | 785 | | |
786 | 786 | | |
787 | 787 | | |
788 | | - | |
| 788 | + | |
789 | 789 | | |
790 | 790 | | |
791 | 791 | | |
| |||
0 commit comments