comparison src/testdir/test_autocmd.vim @ 31849:dbec60b8c253 v9.0.1257

patch 9.0.1257: code style is not check in test scripts Commit: https://github.com/vim/vim/commit/94722c510745a0cfd494c51625a514b92dd2bfb2 Author: Bram Moolenaar <Bram@vim.org> Date: Sat Jan 28 19:19:03 2023 +0000 patch 9.0.1257: code style is not check in test scripts Problem: Code style is not check in test scripts. Solution: Add basic code style check for test files.
author Bram Moolenaar <Bram@vim.org>
date Sat, 28 Jan 2023 20:30:04 +0100
parents 6969fac11aaa
children dd38c6cc04bd
comparison
equal deleted inserted replaced
31848:b83cac410fcf 31849:dbec60b8c253
267 let g:record = [] 267 let g:record = []
268 268
269 augroup testing 269 augroup testing
270 au WinNew * call add(g:record, 'WinNew') 270 au WinNew * call add(g:record, 'WinNew')
271 au WinClosed * call add(g:record, 'WinClosed') 271 au WinClosed * call add(g:record, 'WinClosed')
272 au WinEnter * call add(g:record, 'WinEnter') 272 au WinEnter * call add(g:record, 'WinEnter')
273 au WinLeave * call add(g:record, 'WinLeave') 273 au WinLeave * call add(g:record, 'WinLeave')
274 au TabNew * call add(g:record, 'TabNew') 274 au TabNew * call add(g:record, 'TabNew')
275 au TabClosed * call add(g:record, 'TabClosed') 275 au TabClosed * call add(g:record, 'TabClosed')
276 au TabEnter * call add(g:record, 'TabEnter') 276 au TabEnter * call add(g:record, 'TabEnter')
277 au TabLeave * call add(g:record, 'TabLeave') 277 au TabLeave * call add(g:record, 'TabLeave')
278 augroup END 278 augroup END
3404 %bwipe! 3404 %bwipe!
3405 endfunc 3405 endfunc
3406 3406
3407 func Test_Visual_doautoall_redraw() 3407 func Test_Visual_doautoall_redraw()
3408 call setline(1, ['a', 'b']) 3408 call setline(1, ['a', 'b'])
3409 new 3409 new
3410 wincmd p 3410 wincmd p
3411 call feedkeys("G\<C-V>", 'txn') 3411 call feedkeys("G\<C-V>", 'txn')
3412 autocmd User Explode ++once redraw 3412 autocmd User Explode ++once redraw
3413 doautoall User Explode 3413 doautoall User Explode
3414 %bwipe! 3414 %bwipe!
4119 call assert_true(autocmd_delete([test_null_dict()])) 4119 call assert_true(autocmd_delete([test_null_dict()]))
4120 endfunc 4120 endfunc
4121 4121
4122 func Test_autocmd_split_dummy() 4122 func Test_autocmd_split_dummy()
4123 " Autocommand trying to split a window containing a dummy buffer. 4123 " Autocommand trying to split a window containing a dummy buffer.
4124 auto BufReadPre * exe "sbuf " .. expand("<abuf>") 4124 auto BufReadPre * exe "sbuf " .. expand("<abuf>")
4125 " Avoid the "W11" prompt 4125 " Avoid the "W11" prompt
4126 au FileChangedShell * let v:fcs_choice = 'reload' 4126 au FileChangedShell * let v:fcs_choice = 'reload'
4127 func Xautocmd_changelist() 4127 func Xautocmd_changelist()
4128 cal writefile(['Xtestfile2:4:4'], 'Xerr') 4128 cal writefile(['Xtestfile2:4:4'], 'Xerr')
4129 edit Xerr 4129 edit Xerr