comparison src/testdir/test_autocmd.vim @ 19435:8f8a5a15d00a v8.2.0275

patch 8.2.0275: some Ex code not covered by tests Commit: https://github.com/vim/vim/commit/406cd90f1963ca60813db91c413eef4b1b78ee44 Author: Bram Moolenaar <Bram@vim.org> Date: Tue Feb 18 21:54:41 2020 +0100 patch 8.2.0275: some Ex code not covered by tests Problem: Some Ex code not covered by tests. Solution: Add test cases. (Yegappan Lakshmanan, closes https://github.com/vim/vim/issues/5659)
author Bram Moolenaar <Bram@vim.org>
date Tue, 18 Feb 2020 22:00:04 +0100
parents 67fbe280a502
children 31ac050a29a7
comparison
equal deleted inserted replaced
19434:4f7cdab4da93 19435:8f8a5a15d00a
2356 2356
2357 au! crash 2357 au! crash
2358 setglobal spellfile= 2358 setglobal spellfile=
2359 endfunc 2359 endfunc
2360 2360
2361 " Test closing a window or editing another buffer from a FileChangedRO handler
2362 " in a readonly buffer
2363 func Test_FileChangedRO_winclose()
2364 augroup FileChangedROTest
2365 au!
2366 autocmd FileChangedRO * quit
2367 augroup END
2368 new
2369 set readonly
2370 call assert_fails('normal i', 'E788:')
2371 close
2372 augroup! FileChangedROTest
2373
2374 augroup FileChangedROTest
2375 au!
2376 autocmd FileChangedRO * edit Xfile
2377 augroup END
2378 new
2379 set readonly
2380 call assert_fails('normal i', 'E788:')
2381 close
2382 augroup! FileChangedROTest
2383 endfunc
2384
2361 " vim: shiftwidth=2 sts=2 expandtab 2385 " vim: shiftwidth=2 sts=2 expandtab