summaryrefslogtreecommitdiffstats
path: root/src/testdir
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2019-12-11 19:00:04 +0100
committerBram Moolenaar <Bram@vim.org>2019-12-11 19:00:04 +0100
commit0efd1bdcf4891f9ef2537e4c3d50a379186dca5f (patch)
treed30f4ed13d1ab221b2483b49b3ae4bd157e15633 /src/testdir
parent99ebf22c523e3fdb491b2c92b6f3a7d42721361d (diff)
patch 8.1.2419: with a long file name the hit-enter prompt appearsv8.1.2419
Problem: With a long file name the hit-enter prompt appears. (J. Lewis Muir) Solution: When checking for text to wrap don't do this when outputing a CR.
Diffstat (limited to 'src/testdir')
-rw-r--r--src/testdir/dumps/Test_long_file_name_1.dump8
-rw-r--r--src/testdir/test_display.vim18
2 files changed, 26 insertions, 0 deletions
diff --git a/src/testdir/dumps/Test_long_file_name_1.dump b/src/testdir/dumps/Test_long_file_name_1.dump
new file mode 100644
index 0000000000..46fa9bdfbe
--- /dev/null
+++ b/src/testdir/dumps/Test_long_file_name_1.dump
@@ -0,0 +1,8 @@
+> +0&#ffffff0@74
+|~+0#4040ff13&| @73
+|~| @73
+|~| @73
+|~| @73
+|~| @73
+|~| @73
+|<+0#0000000&|x@64|"| |0|L|,| |0|C|
diff --git a/src/testdir/test_display.vim b/src/testdir/test_display.vim
index a25d2cfe08..4ef361e05b 100644
--- a/src/testdir/test_display.vim
+++ b/src/testdir/test_display.vim
@@ -181,3 +181,21 @@ func Test_scroll_CursorLineNr_update()
call StopVimInTerminal(buf)
call delete(filename)
endfunc
+
+" check a long file name does not result in the hit-enter prompt
+func Test_edit_long_file_name()
+ CheckScreendump
+
+ let longName = 'x'->repeat(&columns)
+ call writefile([], longName)
+ let buf = RunVimInTerminal('-N -u NONE ' .. longName, #{rows: 8})
+
+ call VerifyScreenDump(buf, 'Test_long_file_name_1', {})
+
+ call term_sendkeys(buf, ":q\<cr>")
+
+ " clean up
+ call StopVimInTerminal(buf)
+ call delete(longName)
+endfunc
+