mirror of
https://github.com/vim/vim.git
synced 2025-09-24 03:44:06 -04:00
patch 8.1.1516: time reported for a test measured wrong
Problem: Time reported for a test measured wrong. Solution: Move the computation to the end of RunTheTest(). (Ozaki Kiichi, closes #4520)
This commit is contained in:
@@ -133,13 +133,6 @@ func RunTheTest(test)
|
|||||||
endtry
|
endtry
|
||||||
endif
|
endif
|
||||||
|
|
||||||
let message = 'Executed ' . a:test
|
|
||||||
if has('reltime')
|
|
||||||
let message ..= ' in ' .. reltimestr(reltime(func_start)) .. ' seconds'
|
|
||||||
endif
|
|
||||||
call add(s:messages, message)
|
|
||||||
let s:done += 1
|
|
||||||
|
|
||||||
if a:test =~ 'Test_nocatch_'
|
if a:test =~ 'Test_nocatch_'
|
||||||
" Function handles errors itself. This avoids skipping commands after the
|
" Function handles errors itself. This avoids skipping commands after the
|
||||||
" error.
|
" error.
|
||||||
@@ -193,6 +186,13 @@ func RunTheTest(test)
|
|||||||
endwhile
|
endwhile
|
||||||
|
|
||||||
exe 'cd ' . save_cwd
|
exe 'cd ' . save_cwd
|
||||||
|
|
||||||
|
let message = 'Executed ' . a:test
|
||||||
|
if has('reltime')
|
||||||
|
let message ..= ' in ' .. reltimestr(reltime(func_start)) .. ' seconds'
|
||||||
|
endif
|
||||||
|
call add(s:messages, message)
|
||||||
|
let s:done += 1
|
||||||
endfunc
|
endfunc
|
||||||
|
|
||||||
func AfterTheTest()
|
func AfterTheTest()
|
||||||
|
@@ -777,6 +777,8 @@ static char *(features[]) =
|
|||||||
|
|
||||||
static int included_patches[] =
|
static int included_patches[] =
|
||||||
{ /* Add new patch number below this line */
|
{ /* Add new patch number below this line */
|
||||||
|
/**/
|
||||||
|
1516,
|
||||||
/**/
|
/**/
|
||||||
1515,
|
1515,
|
||||||
/**/
|
/**/
|
||||||
|
Reference in New Issue
Block a user