diff options
author | Lewis Russell <lewis6991@gmail.com> | 2022-08-06 13:53:37 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-08-06 13:53:37 +0100 |
commit | 0fdf59ac9d30d8874ba6eba22a8bdfb41c1603b7 (patch) | |
tree | e8bb8505e9a341a5b675893b0cfc73882f41bb57 /test/functional/api/vim_spec.lua | |
parent | 0df1418ffab4e9e514422b7074386519fb0d28b2 (diff) | |
download | rneovim-0fdf59ac9d30d8874ba6eba22a8bdfb41c1603b7.tar.gz rneovim-0fdf59ac9d30d8874ba6eba22a8bdfb41c1603b7.tar.bz2 rneovim-0fdf59ac9d30d8874ba6eba22a8bdfb41c1603b7.zip |
fix(api): nvim_cmd handle 0 range (#19655)
Fixes #19608
Diffstat (limited to 'test/functional/api/vim_spec.lua')
-rw-r--r-- | test/functional/api/vim_spec.lua | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/test/functional/api/vim_spec.lua b/test/functional/api/vim_spec.lua index 17de6730fb..fe623ff824 100644 --- a/test/functional/api/vim_spec.lua +++ b/test/functional/api/vim_spec.lua @@ -3822,5 +3822,12 @@ describe('API', function() feed("[l") neq(nil, string.find(eval("v:errmsg"), "E5108:")) end) + it('handles 0 range #19608', function() + meths.buf_set_lines(0, 0, -1, false, { "aa" }) + meths.cmd({ cmd = 'delete', range = { 0 } }, {}) + command('undo') + eq({'aa'}, meths.buf_get_lines(0, 0, 1, false)) + assert_alive() + end) end) end) |