Mercurial > vim
comparison src/testdir/test_checkpath.vim @ 22375:595ea7f099cd v8.2.1736
patch 8.2.1736: failure to compile a pattern not tested much
Commit: https://github.com/vim/vim/commit/531be47ac5522807b265c6287021a01c9b895ac9
Author: Bram Moolenaar <Bram@vim.org>
Date: Wed Sep 23 22:38:05 2020 +0200
patch 8.2.1736: failure to compile a pattern not tested much
Problem: Failure to compile a pattern not tested much.
Solution: Add tests where a pattern fails to compile. (Yegappan Lakshmanan,
closes #7004)
author | Bram Moolenaar <Bram@vim.org> |
---|---|
date | Wed, 23 Sep 2020 22:45:06 +0200 |
parents | 08940efa6b4e |
children | d891115c0aea |
comparison
equal
deleted
inserted
replaced
22374:e9b3a8c9ae2c | 22375:595ea7f099cd |
---|---|
101 set path& | 101 set path& |
102 set include& | 102 set include& |
103 set includeexpr& | 103 set includeexpr& |
104 endfunc | 104 endfunc |
105 | 105 |
106 " Test for invalid regex in 'include' and 'define' options | |
107 func Test_checkpath_errors() | |
108 let save_include = &include | |
109 set include=\\%( | |
110 call assert_fails('checkpath', 'E53:') | |
111 let &include = save_include | |
112 | |
113 let save_define = &define | |
114 set define=\\%( | |
115 call assert_fails('dsearch abc', 'E53:') | |
116 let &define = save_define | |
117 | |
118 call assert_fails('psearch \%(', 'E53:') | |
119 endfunc | |
120 | |
106 " vim: shiftwidth=2 sts=2 expandtab | 121 " vim: shiftwidth=2 sts=2 expandtab |