Bram Moolenaar | bd74325 | 2010-10-20 21:23:33 +0200 | [diff] [blame] | 1 | " Tests for functions. |
| 2 | |
| 3 | STARTTEST |
| 4 | :so small.vim |
Bram Moolenaar | 792826c | 2011-08-19 22:29:02 +0200 | [diff] [blame] | 5 | :set cpo-=< |
Bram Moolenaar | bd74325 | 2010-10-20 21:23:33 +0200 | [diff] [blame] | 6 | :" Test maparg() with a string result |
| 7 | :map foo<C-V> is<F4>foo |
| 8 | :vnoremap <script> <buffer> <expr> <silent> bar isbar |
| 9 | :call append('$', maparg('foo<C-V>')) |
| 10 | :call append('$', string(maparg('foo<C-V>', '', 0, 1))) |
| 11 | :call append('$', string(maparg('bar', '', 0, 1))) |
| 12 | :" |
Bram Moolenaar | 792826c | 2011-08-19 22:29:02 +0200 | [diff] [blame] | 13 | :map abc x<char-114>x |
| 14 | :call append('$', maparg('abc')) |
| 15 | :map abc y<S-char-114>y |
| 16 | :call append('$', maparg('abc')) |
| 17 | :" |
Bram Moolenaar | bd74325 | 2010-10-20 21:23:33 +0200 | [diff] [blame] | 18 | :/^eof/+1,$w! test.out |
| 19 | :qa! |
| 20 | ENDTEST |
| 21 | |
| 22 | eof |