mirror of
https://github.com/neovim/neovim.git
synced 2025-09-30 06:58:35 +00:00
fix(highlight): add missing g: prefix for colors_name
Fix #22951.
This was fixed in Vim in patch 8.2.0613.
(cherry picked from commit a28aa614f5
)
This commit is contained in:

committed by
github-actions[bot]
![github-actions[bot]](/assets/img/avatar_default.png)
parent
92ffc44ce7
commit
d9ceb213d9
@@ -3,6 +3,9 @@ local helpers = require("test.functional.helpers")(after_each)
|
||||
local eq, command = helpers.eq, helpers.command
|
||||
local clear = helpers.clear
|
||||
local eval, exc_exec = helpers.eval, helpers.exc_exec
|
||||
local exec = helpers.exec
|
||||
local funcs = helpers.funcs
|
||||
local meths = helpers.meths
|
||||
|
||||
describe(':highlight', function()
|
||||
local screen
|
||||
@@ -45,4 +48,20 @@ describe(':highlight', function()
|
||||
eq('', eval('synIDattr(hlID("NonText"), "undercurl", "gui")'))
|
||||
eq('1', eval('synIDattr(hlID("NonText"), "underline", "gui")'))
|
||||
end)
|
||||
|
||||
it('clear', function()
|
||||
meths.set_var('colors_name', 'foo')
|
||||
eq(1, funcs.exists('g:colors_name'))
|
||||
command('hi clear')
|
||||
eq(0, funcs.exists('g:colors_name'))
|
||||
meths.set_var('colors_name', 'foo')
|
||||
eq(1, funcs.exists('g:colors_name'))
|
||||
exec([[
|
||||
func HiClear()
|
||||
hi clear
|
||||
endfunc
|
||||
]])
|
||||
funcs.HiClear()
|
||||
eq(0, funcs.exists('g:colors_name'))
|
||||
end)
|
||||
end)
|
||||
|
Reference in New Issue
Block a user