diff options
Diffstat (limited to 'test/functional/lua/snippet_spec.lua')
-rw-r--r-- | test/functional/lua/snippet_spec.lua | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/test/functional/lua/snippet_spec.lua b/test/functional/lua/snippet_spec.lua index f86d73a82b..6f76f46e75 100644 --- a/test/functional/lua/snippet_spec.lua +++ b/test/functional/lua/snippet_spec.lua @@ -216,4 +216,16 @@ describe('vim.snippet', function() feed('foo') eq({ 'public function foo() {', '\t', '}' }, buf_lines(0)) end) + + it('jumps through adjacent tabstops', function() + test_expand_success( + { 'for i=1,${1:to}${2:,step} do\n\t$3\nend' }, + { 'for i=1,to,step do', '\t', 'end' } + ) + feed('10') + feed('<Tab>') + poke_eventloop() + feed(',2') + eq({ 'for i=1,10,2 do', '\t', 'end' }, buf_lines(0)) + end) end) |