comparison src/testdir/test_cmdline.vim @ 20703:ce55e65d7e41 v8.2.0905

patch 8.2.0905: test coverage could be better Commit: https://github.com/vim/vim/commit/e0c3c3d6cbb6f356058f28ecbdf3438411222083 Author: Bram Moolenaar <Bram@vim.org> Date: Thu Jun 4 22:46:04 2020 +0200 patch 8.2.0905: test coverage could be better Problem: Test coverage could be better. Solution: Add a couple of tests. (Dominique Pelle, closes https://github.com/vim/vim/issues/6202)
author Bram Moolenaar <Bram@vim.org>
date Thu, 04 Jun 2020 23:00:03 +0200
parents 0610f1ddb3a0
children abebcc20af26
comparison
equal deleted inserted replaced
20702:1db8701ca6cb 20703:ce55e65d7e41
1218 endif 1218 endif
1219 call delete('Xscript') 1219 call delete('Xscript')
1220 call delete('Xresult') 1220 call delete('Xresult')
1221 endfunc 1221 endfunc
1222 1222
1223 " Test error: "E135: *Filter* Autocommands must not change current buffer"
1224 func Test_cmd_bang_E135()
1225 new
1226 call setline(1, ['a', 'b', 'c', 'd'])
1227 augroup test_cmd_filter_E135
1228 au!
1229 autocmd FilterReadPost * help
1230 augroup END
1231 call assert_fails('2,3!echo "x"', 'E135:')
1232
1233 augroup test_cmd_filter_E135
1234 au!
1235 augroup END
1236 %bwipe!
1237 endfunc
1238
1223 " Test for using ~ for home directory in cmdline completion matches 1239 " Test for using ~ for home directory in cmdline completion matches
1224 func Test_cmdline_expand_home() 1240 func Test_cmdline_expand_home()
1225 call mkdir('Xdir') 1241 call mkdir('Xdir')
1226 call writefile([], 'Xdir/Xfile1') 1242 call writefile([], 'Xdir/Xfile1')
1227 call writefile([], 'Xdir/Xfile2') 1243 call writefile([], 'Xdir/Xfile2')