patch 9.1.1249: tests: no test that 'listchars' "eol" doesn't affect "gM"
Problem: No test that 'listchars' "eol" doesn't affect "gM".
Solution: Add a test (zeertzjq).
closes: #16990
Signed-off-by: zeertzjq <zeertzjq@outlook.com>
Signed-off-by: Christian Brabandt <cb@256bit.org>
diff --git a/src/testdir/test_normal.vim b/src/testdir/test_normal.vim
index 75a3028..35c290c 100644
--- a/src/testdir/test_normal.vim
+++ b/src/testdir/test_normal.vim
@@ -2698,6 +2698,22 @@
call assert_equal(87, col('.'))
call assert_equal('E', getreg(0))
+ " Have an odd number of chars in the line
+ norm! A.
+ call assert_equal(145, col('.'))
+ norm! gMyl
+ call assert_equal(73, col('.'))
+ call assert_equal('0', getreg(0))
+
+ " 'listchars' "eol" should not affect gM behavior
+ setlocal list listchars=eol:$
+ norm! $
+ call assert_equal(145, col('.'))
+ norm! gMyl
+ call assert_equal(73, col('.'))
+ call assert_equal('0', getreg(0))
+ setlocal nolist
+
" Test for gM with Tab characters
call setline('.', "\ta\tb\tc\td\te\tf")
norm! gMyl
diff --git a/src/version.c b/src/version.c
index 9569a09..7339d58 100644
--- a/src/version.c
+++ b/src/version.c
@@ -705,6 +705,8 @@
static int included_patches[] =
{ /* Add new patch number below this line */
/**/
+ 1249,
+/**/
1248,
/**/
1247,