aboutsummaryrefslogtreecommitdiff
path: root/test/functional/options/defaults_spec.lua
diff options
context:
space:
mode:
authorMatthieu Coudron <mattator@gmail.com>2018-02-09 08:44:24 +0900
committerJustin M. Keyes <justinkz@gmail.com>2018-02-23 00:48:35 +0100
commit384a39479a0b70abf9cd6ced0b5f1d53cd817c11 (patch)
treee55c16d1a7d134b091e11df06e36025cc8dd8288 /test/functional/options/defaults_spec.lua
parent0c930c2969a8c7cce49382d0acb83e165644af41 (diff)
downloadrneovim-384a39479a0b70abf9cd6ced0b5f1d53cd817c11.tar.gz
rneovim-384a39479a0b70abf9cd6ced0b5f1d53cd817c11.tar.bz2
rneovim-384a39479a0b70abf9cd6ced0b5f1d53cd817c11.zip
'fillchars': fix defaults logic; handle ambiwidth=double #7986
Update tests.
Diffstat (limited to 'test/functional/options/defaults_spec.lua')
-rw-r--r--test/functional/options/defaults_spec.lua36
1 files changed, 35 insertions, 1 deletions
diff --git a/test/functional/options/defaults_spec.lua b/test/functional/options/defaults_spec.lua
index 89d4e56d04..9e29baba2d 100644
--- a/test/functional/options/defaults_spec.lua
+++ b/test/functional/options/defaults_spec.lua
@@ -7,6 +7,7 @@ local command = helpers.command
local clear = helpers.clear
local eval = helpers.eval
local eq = helpers.eq
+local insert = helpers.insert
local neq = helpers.neq
local mkdir = helpers.mkdir
local rmdir = helpers.rmdir
@@ -115,7 +116,40 @@ describe('startup defaults', function()
end)
end)
- describe('packpath', function()
+ describe("'fillchars'", function()
+ it('vert/fold flags', function()
+ clear()
+ local screen = Screen.new(50, 5)
+ screen:attach()
+ command('set laststatus=0')
+ insert([[
+ 1
+ 2
+ 3
+ 4]])
+ command('normal! ggjzfj')
+ command('vsp')
+ screen:expect([[
+ 1 │1 |
+ ^+-- 2 lines: 2··········│+-- 2 lines: 2·········|
+ 4 │4 |
+ ~ │~ |
+ |
+ ]])
+
+ -- ambiwidth=double defaults to single-byte fillchars.
+ command('set ambiwidth=double')
+ screen:expect([[
+ 1 |1 |
+ ^+-- 2 lines: 2----------|+-- 2 lines: 2---------|
+ 4 |4 |
+ ~ |~ |
+ |
+ ]])
+ end)
+ end)
+
+ describe("'packpath'", function()
it('defaults to &runtimepath', function()
eq(meths.get_option('runtimepath'), meths.get_option('packpath'))
end)