diff options
| author | Justin M. Keyes <justinkz@gmail.com> | 2019-06-24 02:35:25 +0200 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2019-06-24 02:35:25 +0200 |
| commit | 7d604a1e6158cda79f7ac485e0ef0e349014f8bf (patch) | |
| tree | 4234b4bc08bfa6023b91f385642d899266bc825a /src/nvim/testdir/test_quickfix.vim | |
| parent | 9fd4a0b52697db053143f51822e68da95c6886aa (diff) | |
| parent | fa3db26f100bcb1c27b62b491bd63aed0800795b (diff) | |
| download | rneovim-7d604a1e6158cda79f7ac485e0ef0e349014f8bf.tar.gz rneovim-7d604a1e6158cda79f7ac485e0ef0e349014f8bf.tar.bz2 rneovim-7d604a1e6158cda79f7ac485e0ef0e349014f8bf.zip | |
Merge #10294 from janlazo/vim-8.0.1239
vim-patch:8.0.1239,8.1.{112,125,165,166,167,169,181,242,270,272,747,850,853,1519}
Diffstat (limited to 'src/nvim/testdir/test_quickfix.vim')
| -rw-r--r-- | src/nvim/testdir/test_quickfix.vim | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/src/nvim/testdir/test_quickfix.vim b/src/nvim/testdir/test_quickfix.vim index 4d78c67f5c..ce0b8f1be8 100644 --- a/src/nvim/testdir/test_quickfix.vim +++ b/src/nvim/testdir/test_quickfix.vim @@ -3373,6 +3373,23 @@ func Test_lbuffer_with_bwipe() augroup END endfunc +" Tests for the ':filter /pat/ clist' command +func Test_filter_clist() + cexpr ['Xfile1:10:10:Line 10', 'Xfile2:15:15:Line 15'] + call assert_equal([' 2 Xfile2:15 col 15: Line 15'], + \ split(execute('filter /Line 15/ clist'), "\n")) + call assert_equal([' 1 Xfile1:10 col 10: Line 10'], + \ split(execute('filter /Xfile1/ clist'), "\n")) + call assert_equal([], split(execute('filter /abc/ clist'), "\n")) + + call setqflist([{'module' : 'abc', 'pattern' : 'pat1'}, + \ {'module' : 'pqr', 'pattern' : 'pat2'}], ' ') + call assert_equal([' 2 pqr:pat2: '], + \ split(execute('filter /pqr/ clist'), "\n")) + call assert_equal([' 1 abc:pat1: '], + \ split(execute('filter /pat1/ clist'), "\n")) +endfunc + func Test_setloclist_in_aucmd() " This was using freed memory. augroup nasty |