To: vim_dev@googlegroups.com Subject: Patch 8.1.2089 Fcc: outbox From: Bram Moolenaar Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit ------------ Patch 8.1.2089 (after 8.1.2087) Problem: Do not get a hint that $TEST_FILTER was active. Solution: Mention $TEST_FILTER if no functions were executed. Files: src/testdir/runtest.vim *** ../vim-8.1.2088/src/testdir/runtest.vim 2019-09-27 15:34:12.737450489 +0200 --- src/testdir/runtest.vim 2019-09-27 21:07:23.791521952 +0200 *************** *** 253,263 **** endif if s:done == 0 ! let message = 'NO tests executed' else let message = 'Executed ' . s:done . (s:done > 1 ? ' tests' : ' test') endif ! if has('reltime') let message ..= ' in ' .. reltimestr(reltime(s:start_time)) .. ' seconds' endif echo message --- 253,270 ---- endif if s:done == 0 ! if s:filtered > 0 ! let message = "NO tests match $TEST_FILTER: '" .. $TEST_FILTER .. "'" ! else ! let message = 'NO tests executed' ! endif else + if s:filtered > 0 + call add(s:messages, "Filtered " .. s:filtered .. " tests with $TEST_FILTER") + endif let message = 'Executed ' . s:done . (s:done > 1 ? ' tests' : ' test') endif ! if s:done > 0 && has('reltime') let message ..= ' in ' .. reltimestr(reltime(s:start_time)) .. ' seconds' endif echo message *************** *** 386,393 **** --- 393,403 ---- " If the environment variable $TEST_FILTER is set then filter the function " names against it. + let s:filtered = 0 if $TEST_FILTER != '' + let s:filtered = len(s:tests) let s:tests = filter(s:tests, 'v:val =~ $TEST_FILTER') + let s:filtered -= len(s:tests) endif " Execute the tests in alphabetical order. *** ../vim-8.1.2088/src/version.c 2019-09-27 19:35:43.844305437 +0200 --- src/version.c 2019-09-27 21:24:21.872313380 +0200 *************** *** 759,760 **** --- 759,762 ---- { /* Add new patch number below this line */ + /**/ + 2089, /**/ -- Vim is like Emacs without all the typing. (John "Johann" Spetz) /// Bram Moolenaar -- Bram@Moolenaar.net -- 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 ///