Mercurial > vim
comparison src/testdir/test_edit.vim @ 13215:ae5f855a64be v8.0.1482
patch 8.0.1482: using feedkeys() does not work to test completion
commit https://github.com/vim/vim/commit/02ae9b4a93deea4993d7abe20485f91f1cce5e36
Author: Bram Moolenaar <Bram@vim.org>
Date: Fri Feb 9 15:06:02 2018 +0100
patch 8.0.1482: using feedkeys() does not work to test completion
Problem: Using feedkeys() does not work to test Insert mode completion.
(Lifepillar)
Solution: Do not check for typed keys when executing :normal or feedkeys().
Fix thesaurus completion not working when 'complete' is empty.
author | Christian Brabandt <cb@256bit.org> |
---|---|
date | Fri, 09 Feb 2018 15:15:06 +0100 |
parents | 6daad7ef16be |
children | bcda3b864c31 |
comparison
equal
deleted
inserted
replaced
13214:ed51483e9971 | 13215:ae5f855a64be |
---|---|
629 call feedkeys("A\<c-x>\<c-l>\<esc>", 'tnix') | 629 call feedkeys("A\<c-x>\<c-l>\<esc>", 'tnix') |
630 call assert_equal(['one', 'two', 'three', 'three', '', '', ''], getline(1, '$')) | 630 call assert_equal(['one', 'two', 'three', 'three', '', '', ''], getline(1, '$')) |
631 call feedkeys("cct\<c-x>\<c-l>\<c-n>\<esc>", 'tnix') | 631 call feedkeys("cct\<c-x>\<c-l>\<c-n>\<esc>", 'tnix') |
632 call assert_equal(['one', 'two', 'three', 't', '', '', ''], getline(1, '$')) | 632 call assert_equal(['one', 'two', 'three', 't', '', '', ''], getline(1, '$')) |
633 call feedkeys("cct\<c-x>\<c-l>\<c-n>\<c-n>\<esc>", 'tnix') | 633 call feedkeys("cct\<c-x>\<c-l>\<c-n>\<c-n>\<esc>", 'tnix') |
634 call assert_equal(['one', 'two', 'three', 'two', '', '', ''], getline(1, '$')) | |
635 call feedkeys("cct\<c-x>\<c-l>\<c-n>\<c-n>\<c-n>\<esc>", 'tnix') | |
636 call assert_equal(['one', 'two', 'three', 'three', '', '', ''], getline(1, '$')) | |
637 call feedkeys("cct\<c-x>\<c-l>\<c-n>\<c-n>\<c-n>\<c-n>\<esc>", 'tnix') | |
634 call assert_equal(['one', 'two', 'three', 't', '', '', ''], getline(1, '$')) | 638 call assert_equal(['one', 'two', 'three', 't', '', '', ''], getline(1, '$')) |
635 call feedkeys("cct\<c-x>\<c-l>\<c-n>\<c-n>\<c-n>\<esc>", 'tnix') | |
636 call assert_equal(['one', 'two', 'three', 'two', '', '', ''], getline(1, '$')) | |
637 call feedkeys("cct\<c-x>\<c-l>\<c-n>\<c-n>\<c-n>\<c-n>\<esc>", 'tnix') | |
638 call assert_equal(['one', 'two', 'three', 'three', '', '', ''], getline(1, '$')) | |
639 call feedkeys("cct\<c-x>\<c-l>\<c-p>\<esc>", 'tnix') | 639 call feedkeys("cct\<c-x>\<c-l>\<c-p>\<esc>", 'tnix') |
640 call assert_equal(['one', 'two', 'three', 'two', '', '', ''], getline(1, '$')) | 640 call assert_equal(['one', 'two', 'three', 'two', '', '', ''], getline(1, '$')) |
641 call feedkeys("cct\<c-x>\<c-l>\<c-p>\<c-p>\<esc>", 'tnix') | 641 call feedkeys("cct\<c-x>\<c-l>\<c-p>\<c-p>\<esc>", 'tnix') |
642 call assert_equal(['one', 'two', 'three', 't', '', '', ''], getline(1, '$')) | 642 call assert_equal(['one', 'two', 'three', 't', '', '', ''], getline(1, '$')) |
643 call feedkeys("cct\<c-x>\<c-l>\<c-p>\<c-p>\<c-p>\<esc>", 'tnix') | 643 call feedkeys("cct\<c-x>\<c-l>\<c-p>\<c-p>\<c-p>\<esc>", 'tnix') |
1355 let winposx = getwinposx() | 1355 let winposx = getwinposx() |
1356 let winposy = getwinposy() | 1356 let winposy = getwinposy() |
1357 let save_columns = &columns | 1357 let save_columns = &columns |
1358 " Need at least about 1100 columns to reproduce the problem. | 1358 " Need at least about 1100 columns to reproduce the problem. |
1359 set columns=2000 | 1359 set columns=2000 |
1360 call assert_equal(2000, &columns) | |
1361 set noswapfile | 1360 set noswapfile |
1362 | 1361 |
1363 let longfilename = longdirname . '/' . repeat('a', 255) | 1362 let longfilename = longdirname . '/' . repeat('a', 255) |
1364 call writefile(['Totum', 'Table'], longfilename) | 1363 call writefile(['Totum', 'Table'], longfilename) |
1365 new | 1364 new |