diff options
author | Bram Moolenaar <Bram@vim.org> | 2019-07-27 21:23:45 +0200 |
---|---|---|
committer | Bram Moolenaar <Bram@vim.org> | 2019-07-27 21:23:45 +0200 |
commit | 9800bfe0fc7596e8fee97172139f0777bac639fb (patch) | |
tree | 51dc0a95712e83bae8c46cecbf5dba79394b6f02 /src/testdir/test_arglist.vim | |
parent | 14371ed69778107654e39268d0d90982e53ad6e0 (diff) |
patch 8.1.1760: extra line break for wrapping output of :argsv8.1.1760
Problem: Extra line break for wrapping output of :args.
Solution: Avoid the extra line break. (Daniel Hahler, closes #4737)
Diffstat (limited to 'src/testdir/test_arglist.vim')
-rw-r--r-- | src/testdir/test_arglist.vim | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/src/testdir/test_arglist.vim b/src/testdir/test_arglist.vim index 441373beae..f161d6ec18 100644 --- a/src/testdir/test_arglist.vim +++ b/src/testdir/test_arglist.vim @@ -169,6 +169,25 @@ func Test_argument() let &hidden = save_hidden + let save_columns = &columns + let &columns = 79 + exe 'args ' .. join(range(1, 81)) + call assert_equal(join([ + \ '', + \ '[1] 6 11 16 21 26 31 36 41 46 51 56 61 66 71 76 81 ', + \ '2 7 12 17 22 27 32 37 42 47 52 57 62 67 72 77 ', + \ '3 8 13 18 23 28 33 38 43 48 53 58 63 68 73 78 ', + \ '4 9 14 19 24 29 34 39 44 49 54 59 64 69 74 79 ', + \ '5 10 15 20 25 30 35 40 45 50 55 60 65 70 75 80 ', + \ ], "\n"), + \ execute('args')) + + " No trailing newline with one item per row. + let long_arg = repeat('X', 81) + exe 'args ' .. long_arg + call assert_equal("\n[".long_arg.']', execute('args')) + let &columns = save_columns + " Setting argument list should fail when the current buffer has unsaved " changes %argd |