diff options
author | Thomas Vigouroux <tomvig38@gmail.com> | 2020-11-10 15:21:04 +0100 |
---|---|---|
committer | Thomas Vigouroux <tomvig38@gmail.com> | 2020-11-23 15:09:32 +0100 |
commit | 52d76f0a3273ca8d7c6a50c6cf4e44cfde939f73 (patch) | |
tree | ce98657783ef0584092e36f00ff2659afc35b5c3 /test/functional/lua/treesitter_spec.lua | |
parent | 9ff6760b2da9a227a2901adfea24d4ec634d551a (diff) | |
download | rneovim-52d76f0a3273ca8d7c6a50c6cf4e44cfde939f73.tar.gz rneovim-52d76f0a3273ca8d7c6a50c6cf4e44cfde939f73.tar.bz2 rneovim-52d76f0a3273ca8d7c6a50c6cf4e44cfde939f73.zip |
fix(treesitter): allow ranges in set_included_ranges
Diffstat (limited to 'test/functional/lua/treesitter_spec.lua')
-rw-r--r-- | test/functional/lua/treesitter_spec.lua | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/test/functional/lua/treesitter_spec.lua b/test/functional/lua/treesitter_spec.lua index 273a5119cb..65dc1b3e03 100644 --- a/test/functional/lua/treesitter_spec.lua +++ b/test/functional/lua/treesitter_spec.lua @@ -781,6 +781,14 @@ local hl_query = [[ ]] eq(range, { { 0, 0, 18, 1 } }) + + local range_tbl = exec_lua [[ + parser:set_included_regions { { { 0, 0, 17, 1 } } } + parser:parse() + return parser:included_regions() + ]] + + eq(range_tbl, { { { 0, 0, 0, 17, 1, 508 } } }) end) it("allows to set complex ranges", function() if not check_parser() then return end |