Bram Moolenaar | 071d427 | 2004-06-13 20:20:40 +0000 | [diff] [blame] | 1 | Test for autocommand that redefines the argument list, when doing ":all". |
| 2 | |
| 3 | STARTTEST |
| 4 | :so small.vim |
| 5 | :au BufReadPost Xxx2 next Xxx2 Xxx1 |
| 6 | /^start of |
| 7 | A1:.,/end of/w! Xxx1 " write test file Xxx1 |
| 8 | $r2:.,/end of/w! Xxx2 " write test file Xxx2 |
| 9 | $r3:.,/end of/w! Xxx3 " write test file Xxx3 |
| 10 | :next! Xxx1 Xxx2 Xxx3 " redefine arglist; go to Xxx1 |
| 11 | :all " open window for all args |
| 12 | :w! test.out " Write contents of Xxx1 |
| 13 | :w >>test.out " Append contents of last window (Xxx1) |
| 14 | :rew " should now be in Xxx2 |
| 15 | :w >>test.out " Append contents of Xxx2 |
| 16 | :qa! |
| 17 | ENDTEST |
| 18 | |
| 19 | start of test file Xxx |
| 20 | this is a test |
| 21 | this is a test |
| 22 | this is a test |
| 23 | this is a test |
| 24 | end of test file Xxx |