patch 8.1.1913: not easy to compute the space on the command line

Problem:    Not easy to compute the space on the command line.
Solution:   Add v:echospace. (Daniel Hahler, closes #4732)
diff --git a/src/testdir/test_messages.vim b/src/testdir/test_messages.vim
index 8c6c854..f122917 100644
--- a/src/testdir/test_messages.vim
+++ b/src/testdir/test_messages.vim
@@ -155,3 +155,20 @@
   exe buf . 'bwipe!'
   call delete(testfile)
 endfunc
+
+func Test_echospace()
+  set noruler noshowcmd laststatus=1
+  call assert_equal(&columns - 1, v:echospace)
+  split
+  call assert_equal(&columns - 1, v:echospace)
+  set ruler
+  call assert_equal(&columns - 1, v:echospace)
+  close
+  call assert_equal(&columns - 19, v:echospace)
+  set showcmd noruler
+  call assert_equal(&columns - 12, v:echospace)
+  set showcmd ruler
+  call assert_equal(&columns - 29, v:echospace)
+
+  set ruler& showcmd&
+endfunc