]> git.madduck.net Git - etc/vim.git/blob - test/lsp/ui/vim/completion.vimspec

madduck's git repository

Every one of the projects in this repository is available at the canonical URL git://git.madduck.net/madduck/pub/<projectpath> — see each project's metadata for the exact URL.

All patches and comments are welcome. Please squash your changes to logical commits before using git-format-patch and git-send-email to patches@git.madduck.net. If you'd read over the Git project's submission guidelines and adhered to them, I'd be especially grateful.

SSH access, as well as push access can be individually arranged.

If you use my repositories frequently, consider adding the following snippet to ~/.gitconfig and using the third clone URL listed for each project:

[url "git://git.madduck.net/madduck/"]
  insteadOf = madduck:

Squashed '.vim/bundle/vim-lsp/' content from commit 04428c92
[etc/vim.git] / test / lsp / ui / vim / completion.vimspec
1 Describe lsp#uivim#completion
2
3     Before each
4         %delete _
5         setlocal filetype=html
6         setlocal omnifunc=lsp#omni#complete
7     End
8
9     It should expand simple snippet with multibyte chars
10         Skip This test needs asynchronous process and snippetSupport=true
11
12         call setline(1, ['<div class="あいうえお">'])
13         execute "normal! 'gg$ha id\<C-x>\<C-o>\<C-n>\<Tab>'"
14
15         " wait for feedkeys.
16
17         Assert Equals(getline(1), '<div class="あいうえお" id="">')
18         Assert Equals(getpos('.')[1 : 2], [1, 30])
19     End
20
21     It should expand when textEdit.start.character is less than completion start col
22         Skip This test needs asynchronous process and snippetSupport=true
23
24         call setline(1, [
25               \ '<html>',
26               \ '  <div>',
27               \ '    </>',
28               \ '</html>'])
29         execute "normal! ':gg2j$ha\<C-x>\<C-o>\<C-n>\<Tab>'"
30
31         " wait for feedkeys.
32
33         Assert Equals(getline(3), '  </div>')
34         Assert Equals(getpos('.')[1 : 2], [1, 8])
35     End
36
37 End