view src/testdir/test_feedkeys.vim @ 21716:ba99b55d3fb7

Added tag v8.2.1407 for changeset 571832713efa4381d7390f0756b5db03a05301db
author Bram Moolenaar <Bram@vim.org>
date Sun, 09 Aug 2020 17: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