Problem: Cannot easily select one test function to execute.
Solution: Support the $TEST_FILTER environment variable. (Ozaki Kiichi,
closes #2695)
# Run individual NEW style test.
# These do not depend on the executable, compile it when needed.
+# Set $TEST_FILTER to select what test function to invoke, e.g.:
+# export TEST_FILTER=Test_terminal_wipe_buffer
+# A partial match also works:
+# export TEST_FILTER=wipe_buffer
$(NEW_TESTS):
cd testdir; $(MAKE) $@ VIMPROG=../$(VIMTESTTARGET) $(GUI_TESTARG) SCRIPTSOURCE=../$(SCRIPTSOURCE)
let s:tests = filter(s:tests, 'v:val =~ argv(1)')
endif
+" If the environment variable $TEST_FILTER is set then filter the function
+" names against it.
+if $TEST_FILTER != ''
+ let s:tests = filter(s:tests, 'v:val =~ $TEST_FILTER')
+endif
+
" Execute the tests in alphabetical order.
for s:test in sort(s:tests)
" Silence, please!
let g:failed += a:match+0
elseif a:type ==# 'skipped'
let g:skipped += 1
- call extend(g:skipped_output, ["\t".a:match])
+ call extend(g:skipped_output, ["\t" .. a:match])
endif
endfunc
let g:failed_output = []
let output = [""]
+ if $TEST_FILTER != ''
+ call extend(g:skipped_output, ["\tAll tests not matching $TEST_FILTER: '" .. $TEST_FILTER .. "'"])
+ endif
+
try
" This uses the :s command to just fetch and process the output of the
" tests, it doesn't actually replace anything.
static int included_patches[] =
{ /* Add new patch number below this line */
+/**/
+ 2087,
/**/
2086,
/**/