diff options
author | Jan Edmund Lazo <jan.lazo@mail.utoronto.ca> | 2020-08-23 13:22:07 -0400 |
---|---|---|
committer | Jan Edmund Lazo <jan.lazo@mail.utoronto.ca> | 2020-08-23 13:22:14 -0400 |
commit | 3fac3cad75aa41352d5ec35d7c68ed127ff2f970 (patch) | |
tree | 892b241a2b6fae1463b5173c3b6d69407239da45 | |
parent | 8c49e3d50959e24dadd688f56a18f104bd5fd934 (diff) | |
download | rneovim-3fac3cad75aa41352d5ec35d7c68ed127ff2f970.tar.gz rneovim-3fac3cad75aa41352d5ec35d7c68ed127ff2f970.tar.bz2 rneovim-3fac3cad75aa41352d5ec35d7c68ed127ff2f970.zip |
vim-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 vim/vim#4520)
https://github.com/vim/vim/commit/640d4f0c97e686211dc4474b46a83e4435d883c0
-rw-r--r-- | src/nvim/testdir/runtest.vim | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/src/nvim/testdir/runtest.vim b/src/nvim/testdir/runtest.vim index 2bf61b0719..67646cce14 100644 --- a/src/nvim/testdir/runtest.vim +++ b/src/nvim/testdir/runtest.vim @@ -136,13 +136,6 @@ func RunTheTest(test) endtry 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_' " Function handles errors itself. This avoids skipping commands after the " error. @@ -196,6 +189,13 @@ func RunTheTest(test) endwhile 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 func AfterTheTest() |