diff options
author | Bram Moolenaar <Bram@vim.org> | 2016-10-29 14:37:56 +0200 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2016-10-29 14:37:56 +0200 |
commit | 60ef3e81f4a54d9f7ee617d57021f0811ec8ada5 (patch) | |
tree | 7293909f94b2fc7d5ec8e3c586b511ebf036998d /src | |
parent | 35a1f59d635d9a655e1267c18f7cc757afd0d5b0 (diff) |
patch 8.0.0053v8.0.0053
Problem: No test for what 8.0.0047 fixes.
Solution: Add a test. (Hirohito Higashi)
Diffstat (limited to 'src')
-rw-r--r-- | src/testdir/test_popup.vim | 28 | ||||
-rw-r--r-- | src/version.c | 2 |
2 files changed, 29 insertions, 1 deletions
diff --git a/src/testdir/test_popup.vim b/src/testdir/test_popup.vim index cc93ff84fa..f1e2c98c47 100644 --- a/src/testdir/test_popup.vim +++ b/src/testdir/test_popup.vim @@ -378,7 +378,7 @@ func DummyCompleteFour(findstart, base) endif endfunc -" Test that 'completefunc' works when it's OK. +" Test that 'omnifunc' works when it's OK. func Test_omnifunc_with_check() new setlocal omnifunc=DummyCompleteFour @@ -437,5 +437,31 @@ func Test_complete_no_undo() q! endfunc +function! DummyCompleteFive(findstart, base) + if a:findstart + return 0 + else + return [ + \ { 'word': 'January', 'info': "info1-1\n1-2\n1-3" }, + \ { 'word': 'February', 'info': "info2-1\n2-2\n2-3" }, + \ { 'word': 'March', 'info': "info3-1\n3-2\n3-3" }, + \ { 'word': 'April', 'info': "info4-1\n4-2\n4-3" }, + \ { 'word': 'May', 'info': "info5-1\n5-2\n5-3" }, + \ ] + endif +endfunc + +" Test that 'completefunc' on Scratch buffer with preview window works when +" it's OK. +func Test_completefunc_with_scratch_buffer() + new +setlocal\ buftype=nofile\ bufhidden=wipe\ noswapfile + set completeopt+=preview + setlocal completefunc=DummyCompleteFive + call feedkeys("A\<C-X>\<C-U>\<C-N>\<C-N>\<C-N>\<Esc>", "x") + call assert_equal(['April'], getline(1, '$')) + pclose + q! + set completeopt& +endfunc " vim: shiftwidth=2 sts=2 expandtab diff --git a/src/version.c b/src/version.c index 5e337d6a17..47c65d6e3e 100644 --- a/src/version.c +++ b/src/version.c @@ -765,6 +765,8 @@ static char *(features[]) = static int included_patches[] = { /* Add new patch number below this line */ /**/ + 53, +/**/ 52, /**/ 51, |