view src/testdir/test_feedkeys.vim @ 19633:dd3e5533a7d2 v8.2.0373

patch 8.2.0373: type of term_sendkeys() is unknown Commit: https://github.com/vim/vim/commit/3a05ce63feae040cd817be289e84c2a7e653d59d Author: Bram Moolenaar <Bram@vim.org> Date: Wed Mar 11 19:30:01 2020 +0100 patch 8.2.0373: type of term_sendkeys() is unknown Problem: Type of term_sendkeys() is unknown. Solution: Just return zero. (closes https://github.com/vim/vim/issues/5762)
author Bram Moolenaar <Bram@vim.org>
date Wed, 11 Mar 2020 21:31:04 +0100
parents 6b70b9cdebfc
children 08940efa6b4e
line wrap: on
line source

" Test feedkeys() function.

func Test_feedkeys_x_with_empty_string()
  new
  call feedkeys("ifoo\<Esc>")
  call assert_equal('', getline('.'))
  call feedkeys('', 'x')
  call assert_equal('foo', getline('.'))

  " check it goes back to normal mode immediately.
  call feedkeys('i', 'x')
  call assert_equal('foo', getline('.'))
  quit!
endfunc