diff src/testdir/test_popup.vim @ 18767:068337e86133 v8.1.2373

patch 8.1.2373: cannot build with +popupwin but without +quickfix Commit: https://github.com/vim/vim/commit/5a4c3082d7ab51b3d448a91578479c96c1ab0ad3 Author: Bram Moolenaar <Bram@vim.org> Date: Sun Dec 1 15:23:11 2019 +0100 patch 8.1.2373: cannot build with +popupwin but without +quickfix Problem: Cannot build with +popupwin but without +quickfix. (John Marriott) Solution: Adjust #ifdefs.
author Bram Moolenaar <Bram@vim.org>
date Sun, 01 Dec 2019 15:30:04 +0100
parents de350001150c
children da791e5c0139
line wrap: on
line diff
--- a/src/testdir/test_popup.vim
+++ b/src/testdir/test_popup.vim
@@ -490,6 +490,8 @@ endfunc
 " Test that 'completefunc' on Scratch buffer with preview window works when
 " it's OK.
 func Test_completefunc_with_scratch_buffer()
+  CheckFeature quickfix
+
   new +setlocal\ buftype=nofile\ bufhidden=wipe\ noswapfile
   set completeopt+=preview
   setlocal completefunc=DummyCompleteFive
@@ -665,6 +667,7 @@ endfunc
 
 func Test_popup_and_window_resize()
   CheckFeature terminal
+  CheckFeature quickfix
   CheckNotGui
 
   let h = winheight(0)
@@ -697,14 +700,13 @@ func Test_popup_and_window_resize()
 endfunc
 
 func Test_popup_and_preview_autocommand()
-  " This used to crash Vim
-  if !has('python')
-    return
+  CheckFeature python
+  CheckFeature quickfix
+  if winheight(0) < 15
+    throw 'Skipped: window height insufficient'
   endif
-  let h = winheight(0)
-  if h < 15
-    return
-  endif
+
+  " This used to crash Vim
   new
   augroup MyBufAdd
     au!
@@ -735,9 +737,9 @@ func Test_popup_and_preview_autocommand(
 endfunc
 
 func Test_popup_and_previewwindow_dump()
-  if !CanRunVimInTerminal()
-    throw 'Skipped: cannot make screendumps'
-  endif
+  CheckScreendump
+  CheckFeature quickfix
+
   let lines =<< trim END
     set previewheight=9
     silent! pedit
@@ -804,9 +806,8 @@ func Test_balloon_split()
 endfunc
 
 func Test_popup_position()
-  if !CanRunVimInTerminal()
-    throw 'Skipped: cannot make screendumps'
-  endif
+  CheckScreendump
+
   let lines =<< trim END
     123456789_123456789_123456789_a
     123456789_123456789_123456789_b
@@ -847,9 +848,8 @@ func Test_popup_position()
 endfunc
 
 func Test_popup_command()
-  if !CanRunVimInTerminal() || !has('menu')
-    throw 'Skipped: cannot make screendumps and/or menu feature missing'
-  endif
+  CheckScreendump
+  CheckFeature menu
 
   let lines =<< trim END
 	one two three four five