diff options
| author | TJ DeVries <devries.timothyj@gmail.com> | 2020-08-29 22:55:48 -0400 |
|---|---|---|
| committer | TJ DeVries <devries.timothyj@gmail.com> | 2020-08-29 22:55:48 -0400 |
| commit | 9bb62777b251ddc7a277debf19f0b3796e8ec81f (patch) | |
| tree | d1aba4b63547036135deb9b2d2ceaf38c2005077 /lua/tests/telescope_spec.lua | |
| parent | fc534a58d8d5bb68a3f8e9ba0e12956be990832e (diff) | |
fix: Think I fixed the weird movements
Diffstat (limited to 'lua/tests/telescope_spec.lua')
| -rw-r--r-- | lua/tests/telescope_spec.lua | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/lua/tests/telescope_spec.lua b/lua/tests/telescope_spec.lua index de2de2e..e98226d 100644 --- a/lua/tests/telescope_spec.lua +++ b/lua/tests/telescope_spec.lua @@ -222,6 +222,15 @@ describe('Sorters', function() assert(exact_match < ok_match) assert(ok_match < no_match) end) + + it('sorts multiple finds better', function() + local sorter = require('telescope.sorters').get_norcalli_sorter() + + local multi_match = sorter:score('generics', 'exercises/generics/generics2.rs') + local one_match = sorter:score('abcdef', 'exercises/generics/README.md') + + assert(multi_match < one_match) + end) end) end) |
