To: vim_dev@googlegroups.com Subject: Patch 8.0.0200 Fcc: outbox From: Bram Moolenaar Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ------------ Patch 8.0.0200 Problem: Some syntax arguments are not tested. Solution: Add more syntax command tests. Files: src/testdir/test_syntax.vim *** ../vim-8.0.0199/src/testdir/test_syntax.vim 2017-01-17 16:27:01.617153072 +0100 --- src/testdir/test_syntax.vim 2017-01-17 17:17:04.089556288 +0100 *************** *** 186,191 **** --- 186,195 ---- call assert_match('conceal on', execute('syntax conceal')) syn clear call assert_match('conceal off', execute('syntax conceal')) + + syntax conceal on + syntax conceal off + call assert_match('conceal off', execute('syntax conceal')) endif syntax region Tar start=// *************** *** 283,290 **** endif call assert_match('on C-style comments', execute('syntax sync')) call assert_match('maximal 5 lines', execute('syntax sync')) ! syn clear ! syn keyword Foo foo if 0 syn sync ccomment endif --- 287,293 ---- endif call assert_match('on C-style comments', execute('syntax sync')) call assert_match('maximal 5 lines', execute('syntax sync')) ! syn sync clear if 0 syn sync ccomment endif *************** *** 293,295 **** --- 296,325 ---- syn clear endfunc + func Test_invalid_arg() + call assert_fails('syntax case asdf', 'E390:') + call assert_fails('syntax conceal asdf', 'E390:') + call assert_fails('syntax spell asdf', 'E390:') + endfunc + + func Test_syn_sync() + syntax region HereGroup start=/this/ end=/that/ + syntax sync match SyncHere grouphere HereGroup "pattern" + call assert_match('SyncHere', execute('syntax sync')) + syn sync clear + call assert_notmatch('SyncHere', execute('syntax sync')) + syn clear + endfunc + + func Test_syn_clear() + syntax keyword Foo foo + syntax keyword Tar tar + call assert_match('Foo', execute('syntax')) + call assert_match('Tar', execute('syntax')) + syn clear Foo + call assert_notmatch('Foo', execute('syntax')) + call assert_match('Tar', execute('syntax')) + syn clear Foo Tar + call assert_notmatch('Foo', execute('syntax')) + call assert_notmatch('Tar', execute('syntax')) + endfunc *** ../vim-8.0.0199/src/version.c 2017-01-17 16:45:00.174121747 +0100 --- src/version.c 2017-01-17 17:03:49.794735182 +0100 *************** *** 766,767 **** --- 766,769 ---- { /* Add new patch number below this line */ + /**/ + 200, /**/ -- When danger reared its ugly head, He bravely turned his tail and fled Yes, Brave Sir Robin turned about And gallantly he chickened out Bravely taking to his feet He beat a very brave retreat Bravest of the brave Sir Robin Petrified of being dead Soiled his pants then brave Sir Robin Turned away and fled. "Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD /// Bram Moolenaar -- Bram@Moolenaar.net -- http://www.Moolenaar.net \\\ /// sponsor Vim, vote for features -- http://www.Vim.org/sponsor/ \\\ \\\ an exciting new programming language -- http://www.Zimbu.org /// \\\ help me help AIDS victims -- http://ICCF-Holland.org ///