mirror of
https://github.com/neovim/neovim.git
synced 2025-02-25 18:55:25 -06:00
test
This commit is contained in:
parent
7268d49c50
commit
aca002e7d5
@ -375,16 +375,22 @@ describe('VimL dictionary notifications', function()
|
|||||||
source([[
|
source([[
|
||||||
let g:d = {}
|
let g:d = {}
|
||||||
|
|
||||||
function! W(...)
|
function! W1(...)
|
||||||
call dictwatcherdel(g:d, '*', function('W'))
|
" Delete current and following watcher.
|
||||||
|
call dictwatcherdel(g:d, '*', function('W1'))
|
||||||
|
call dictwatcherdel(g:d, '*', function('W2'))
|
||||||
try
|
try
|
||||||
call dictwatcherdel({}, 'meh', function('tr'))
|
call dictwatcherdel({}, 'meh', function('tr'))
|
||||||
catch
|
catch
|
||||||
let g:exc = v:exception
|
let g:exc = v:exception
|
||||||
endtry
|
endtry
|
||||||
endfunction
|
endfunction
|
||||||
|
call dictwatcheradd(g:d, '*', function('W1'))
|
||||||
|
|
||||||
|
function! W2(...)
|
||||||
|
endfunction
|
||||||
|
call dictwatcheradd(g:d, '*', function('W2'))
|
||||||
|
|
||||||
call dictwatcheradd(g:d, '*', function('W'))
|
|
||||||
let g:d.foo = 23
|
let g:d.foo = 23
|
||||||
]])
|
]])
|
||||||
eq(23, eval('g:d.foo'))
|
eq(23, eval('g:d.foo'))
|
||||||
|
Loading…
Reference in New Issue
Block a user