view src/testdir/test_curswant.vim @ 24188:c20e763bc73c v8.2.2635

patch 8.2.2635: Vim9: cannot define an inline function Commit: https://github.com/vim/vim/commit/7a6eaa06f98cef61d2131c25b4b47b8262cb8f59 Author: Bram Moolenaar <Bram@vim.org> Date: Sun Mar 21 20:53:29 2021 +0100 patch 8.2.2635: Vim9: cannot define an inline function Problem: Vim9: cannot define an inline function. Solution: Make an inline function mostly work.
author Bram Moolenaar <Bram@vim.org>
date Sun, 21 Mar 2021 21:00:05 +0100
parents 08940efa6b4e
children
line wrap: on
line source

" Tests for curswant not changing when setting an option

func Test_curswant()
  new
  call append(0, ['1234567890', '12345'])

  normal! ggf8j
  call assert_equal(7, winsaveview().curswant)
  let &tabstop=&tabstop
  call assert_equal(4, winsaveview().curswant)

  normal! ggf8j
  call assert_equal(7, winsaveview().curswant)
  let &timeoutlen=&timeoutlen
  call assert_equal(7, winsaveview().curswant)

  normal! ggf8j
  call assert_equal(7, winsaveview().curswant)
  let &ttimeoutlen=&ttimeoutlen
  call assert_equal(7, winsaveview().curswant)

  enew!
endfunc

" vim: shiftwidth=2 sts=2 expandtab