]> granicus.if.org Git - vim/commitdiff
patch 7.4.2085 v7.4.2085
authorBram Moolenaar <Bram@vim.org>
Thu, 21 Jul 2016 08:11:03 +0000 (10:11 +0200)
committerBram Moolenaar <Bram@vim.org>
Thu, 21 Jul 2016 08:11:03 +0000 (10:11 +0200)
Problem:    Digraph tests fails on some systems.
Solution:   Run it separately and set 'encoding' early.

src/testdir/Make_all.mak
src/testdir/test_alot.vim
src/testdir/test_digraph.vim
src/version.c

index 9b8770d53b434d07b35bd1431f230614423c04ae..11cc93429e5186e7e1cabe2c5d5aa81c0612d162 100644 (file)
@@ -170,6 +170,7 @@ NEW_TESTS = test_arglist.res \
            test_channel.res \
            test_cmdline.res \
            test_cscope.res \
+           test_digraph.res \
            test_farsi.res \
            test_hardcopy.res \
            test_history.res \
index e87ff90ebf9848405f64b18ebcd7d2714e24b062..e9c84398e89ed3e125834287e91e0acaa066a204 100644 (file)
@@ -5,7 +5,6 @@ source test_assign.vim
 source test_autocmd.vim
 source test_cursor_func.vim
 source test_delete.vim
-source test_digraph.vim
 source test_execute_func.vim
 source test_ex_undo.vim
 source test_expand.vim
index b12e19fa7cc0ac5e45c2359fa4cc4a15d9994d98..60ae1fd3f4ca7437f8c9f29bf8ea88250c6e0050 100644 (file)
@@ -4,6 +4,7 @@ if !has("digraphs") || !has("multi_byte")
   finish
 endif
 
+set enc=utf-8
 scriptencoding utf-8
 
 func! Put_Dig(chars)
@@ -15,8 +16,6 @@ func! Put_Dig_BS(char1, char2)
 endfu
 
 func! Test_digraphs()
-  let _enc = &enc
-  set enc=utf8
   new
   call Put_Dig("00")
   call assert_equal("∞", getline('.'))
@@ -215,16 +214,13 @@ func! Test_digraphs()
   call Put_Dig("00")
   call Put_Dig("el")
   call assert_equal(['␀', 'ü', '∞', 'l'], getline(line('.')-3,line('.')))
-  " reset encoding option
-  let &enc = _enc
   bw!
 endfunc
 
 func! Test_digraphs_option()
-  let _enc=&enc
   " reset whichwrap option, so that testing <esc><bs>A works,
   " without moving up a line
-  set enc=utf8 digraph ww=
+  set digraph ww=
   new
   call Put_Dig_BS("0","0")
   call assert_equal("∞", getline('.'))
@@ -423,8 +419,6 @@ func! Test_digraphs_option()
   call Put_Dig_BS("0","0")
   call Put_Dig_BS("e","l")
   call assert_equal(['␀', 'ü', '∞', 'l'], getline(line('.')-3,line('.')))
-  " reset encoding option
-  let &enc = _enc
   set nodigraph ww&vim
   bw!
 endfunc
index 167d405589308d84305ccae4b726e532ef817530..6f9ce5d30d03b693f59ced2f0578fee3f71892eb 100644 (file)
@@ -758,6 +758,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    2085,
 /**/
     2084,
 /**/