view src/testdir/test_lua.vim @ 11999:94e37fd22556 v8.0.0880

patch 8.0.0880: Travis uses an old Ubuntu version commit https://github.com/vim/vim/commit/02113ed4dfa585b4553a7c630b4d7eed0002aebd Author: Bram Moolenaar <Bram@vim.org> Date: Sun Aug 6 17:06:24 2017 +0200 patch 8.0.0880: Travis uses an old Ubuntu version Problem: Travis uses an old Ubuntu version. Solution: Switch from precise to trusty. (Ken Takata, closes https://github.com/vim/vim/issues/1897)
author Christian Brabandt <cb@256bit.org>
date Sun, 06 Aug 2017 17:15:04 +0200
parents 6c3d42d18366
children 2e95ea9afa1e
line wrap: on
line source

" Tests for Lua.
" TODO: move tests from test85.in here.

if !has('lua')
  finish
endif

func Test_luado()
  new
  call setline(1, ['one', 'two', 'three'])
  luado vim.command("%d_")
  bwipe!

  " Check switching to another buffer does not trigger ml_get error.
  new
  let wincount = winnr('$')
  call setline(1, ['one', 'two', 'three'])
  luado vim.command("new")
  call assert_equal(wincount + 1, winnr('$'))
  bwipe!
  bwipe!
endfunc