aboutsummaryrefslogtreecommitdiff
path: root/src/nvim/testdir/test_utf8.vim
diff options
context:
space:
mode:
Diffstat (limited to 'src/nvim/testdir/test_utf8.vim')
-rw-r--r--src/nvim/testdir/test_utf8.vim20
1 files changed, 20 insertions, 0 deletions
diff --git a/src/nvim/testdir/test_utf8.vim b/src/nvim/testdir/test_utf8.vim
index 9146cf7ab3..255f179fc9 100644
--- a/src/nvim/testdir/test_utf8.vim
+++ b/src/nvim/testdir/test_utf8.vim
@@ -199,6 +199,26 @@ func Test_setcellwidths()
call setcellwidths([])
endfunc
+func Test_getcellwidths()
+ call setcellwidths([])
+ call assert_equal([], getcellwidths())
+
+ let widthlist = [
+ \ [0x1330, 0x1330, 2],
+ \ [9999, 10000, 1],
+ \ [0x1337, 0x1339, 2],
+ \]
+ let widthlistsorted = [
+ \ [0x1330, 0x1330, 2],
+ \ [0x1337, 0x1339, 2],
+ \ [9999, 10000, 1],
+ \]
+ call setcellwidths(widthlist)
+ call assert_equal(widthlistsorted, getcellwidths())
+
+ call setcellwidths([])
+endfunc
+
func Test_setcellwidths_dump()
CheckRunVimInTerminal