view src/testdir/test_feedkeys.vim @ 18117:0a89f6f6de87

Added tag v8.1.2053 for changeset 7f57ea9a4ba88f83fea1ec09d7ae8ded877d13f4
author Bram Moolenaar <Bram@vim.org>
date Wed, 18 Sep 2019 21:30:04 +0200
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