Patch 8.0.0558
Problem: The :ownsyntax command is not tested.
Solution: Add a test. (Dominique Pelle, closes #1622)
Files: src/testdir/test_syntax.vim
*** ../vim-8.0.0557/src/testdir/test_syntax.vim 2017-03-26 13:50:02.536929400
+0200
--- src/testdir/test_syntax.vim 2017-04-09 15:39:30.041476398 +0200
***************
*** 349,351 ****
--- 349,380 ----
hi clear Nop
hi clear @Wrong
endfunc
+
+ func Test_ownsyntax()
+ new Xfoo
+ call setline(1, '#define FOO')
+ syntax on
+ set filetype=c
+ ownsyntax perl
+ call assert_equal('perlComment', synIDattr(synID(line('.'), col('.'), 1),
'name'))
+ call assert_equal('c', b:current_syntax)
+ call assert_equal('perl', w:current_syntax)
+
+ " A new split window should have the original syntax.
+ split
+ call assert_equal('cDefine', synIDattr(synID(line('.'), col('.'), 1),
'name'))
+ call assert_equal('c', b:current_syntax)
+ call assert_equal(0, exists('w:current_syntax'))
+
+ wincmd x
+ call assert_equal('perlComment', synIDattr(synID(line("."), col("."), 1),
"name"))
+
+ syntax off
+ set filetype&
+ %bw!
+ endfunc
+
+ func Test_ownsyntax_completion()
+ call feedkeys(":ownsyntax java\<C-A>\<C-B>\"\<CR>", 'tx')
+ call assert_equal('"ownsyntax java javacc javascript', @:)
+ endfunc
*** ../vim-8.0.0557/src/version.c 2017-04-09 15:27:05.798135087 +0200
--- src/version.c 2017-04-09 15:40:44.037013557 +0200
***************
*** 766,767 ****
--- 766,769 ----
{ /* Add new patch number below this line */
+ /**/
+ 558,
/**/
--
TALL KNIGHT OF NI: Ni!
"Monty Python and the Holy Grail" PYTHON (MONTY) PICTURES LTD
/// Bram Moolenaar -- [email protected] -- 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 ///
--
--
You received this message from the "vim_dev" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
---
You received this message because you are subscribed to the Google Groups
"vim_dev" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.