summaryrefslogtreecommitdiffstats
path: root/src/testdir/test_bufwintabinfo.vim
diff options
context:
space:
mode:
authorBram Moolenaar <Bram@vim.org>2016-09-12 19:51:11 +0200
committerBram Moolenaar <Bram@vim.org>2016-09-12 19:51:11 +0200
commit789a5c0e3d27f09456678f0cfb6c1bd2d8ab4a35 (patch)
tree875f09d9d7041be17b9ccf6e1aaaf5969391bd57 /src/testdir/test_bufwintabinfo.vim
parentb56e7ff0dbbfa85361bdbc5b4a86ff8b57a7acbb (diff)
patch 8.0.0003v8.0.0003
Problem: getwinvar() returns wrong Value of boolean and number options, especially non big endian systems. (James McCoy) Solution: Cast the pointer to long or int. (closes #1060)
Diffstat (limited to 'src/testdir/test_bufwintabinfo.vim')
-rw-r--r--src/testdir/test_bufwintabinfo.vim13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/testdir/test_bufwintabinfo.vim b/src/testdir/test_bufwintabinfo.vim
index 5c916e2dd7..1c9350c416 100644
--- a/src/testdir/test_bufwintabinfo.vim
+++ b/src/testdir/test_bufwintabinfo.vim
@@ -87,9 +87,17 @@ function Test_get_buf_options()
endfunc
function Test_get_win_options()
+ if has('folding')
+ set foldlevel=999
+ endif
+ set list
let opts = getwinvar(1, '&')
call assert_equal(v:t_dict, type(opts))
call assert_equal(0, opts.linebreak)
+ call assert_equal(1, opts.list)
+ if has('folding')
+ call assert_equal(999, opts.foldlevel)
+ endif
if has('signs')
call assert_equal('auto', opts.signcolumn)
endif
@@ -97,7 +105,12 @@ function Test_get_win_options()
let opts = gettabwinvar(1, 1, '&')
call assert_equal(v:t_dict, type(opts))
call assert_equal(0, opts.linebreak)
+ call assert_equal(1, opts.list)
if has('signs')
call assert_equal('auto', opts.signcolumn)
endif
+ set list&
+ if has('folding')
+ set foldlevel=0
+ endif
endfunc