]> granicus.if.org Git - vim/commitdiff
patch 8.0.0407: filtering folds with marker method not tested v8.0.0407
authorBram Moolenaar <Bram@vim.org>
Sat, 4 Mar 2017 14:28:53 +0000 (15:28 +0100)
committerBram Moolenaar <Bram@vim.org>
Sat, 4 Mar 2017 14:28:53 +0000 (15:28 +0100)
Problem:    Filtering folds with marker method not tested.
Solution:   Also set 'foldmethod' to "marker".

src/testdir/test_fold.vim
src/version.c

index 1f835b876fec8c0df4b5858c75a8b108fde3d8ad..cdf9fd314214e3d667b477dc5350c2b78ff5e8d0 100644 (file)
@@ -100,15 +100,20 @@ func Test_manual_fold_with_filter()
   if !executable('cat')
     return
   endif
-  new
-  call setline(1, range(1, 20))
-  4,$fold
-  %foldopen
-  10,$fold
-  %foldopen
-  " This filter command should not have an effect
-  1,8! cat
-  call feedkeys('5ggzdzMGdd', 'xt')
-  call assert_equal(['1', '2', '3', '4', '5', '6', '7', '8', '9'], getline(1, '$'))
-  bwipe!
+  for type in ['manual', 'marker']
+    exe 'set foldmethod=' . type
+    new
+    call setline(1, range(1, 20))
+    4,$fold
+    %foldopen
+    10,$fold
+    %foldopen
+    " This filter command should not have an effect
+    1,8! cat
+    call feedkeys('5ggzdzMGdd', 'xt')
+    call assert_equal(['1', '2', '3', '4', '5', '6', '7', '8', '9'], getline(1, '$'))
+
+    bwipe!
+    set foldmethod&
+  endfor
 endfunc
index cc69b3cbb0547f8a3d384c7c02f37ae9357494b8..39c6b4e41ae720846c3ac54b10626c101acc4a95 100644 (file)
@@ -764,6 +764,8 @@ static char *(features[]) =
 
 static int included_patches[] =
 {   /* Add new patch number below this line */
+/**/
+    407,
 /**/
     406,
 /**/